From 61bba0c35587e884a6100b5273c47ada0d223e13 Mon Sep 17 00:00:00 2001 From: speakeasybot Date: Thu, 8 May 2025 00:20:53 +0000 Subject: [PATCH 1/2] ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.542.3 --- .gitignore | 4 + .speakeasy/gen.lock | 1371 ++++------ .speakeasy/gen.yaml | 3 +- .speakeasy/workflow.lock | 16 +- FUNCTIONS.md | 15 +- README.md | 173 +- RELEASES.md | 12 +- USAGE.md | 83 +- .../components/activitiesresponsedto.md | 56 +- .../components/activitygraphstatesresponse.md | 4 +- ...ynotificationexecutiondetailresponsedto.md | 6 +- .../activitynotificationjobresponsedto.md | 20 +- ...tivitynotificationjobresponsedtopayload.md | 16 + .../activitynotificationjobresponsedtotype.md | 2 +- .../activitynotificationresponsedto.md | 44 +- .../activitynotificationstepresponsedto.md | 8 +- ...vitynotificationstepresponsedtometadata.md | 16 + .../components/activitystatsresponsedto.md | 4 +- docs/models/components/actorfeeditemdto.md | 2 +- docs/models/components/actortypeenum.md | 2 +- docs/models/components/backoffunit.md | 2 +- .../models/components/builderfieldtypeenum.md | 2 +- docs/models/components/bulktriggereventdto.md | 12 +- docs/models/components/channel.md | 2 +- docs/models/components/channels.md | 2 +- docs/models/components/channelsettingsdto.md | 14 +- docs/models/components/channeltypeenum.md | 2 +- ...roviderid.md => chatorpushproviderenum.md} | 6 +- .../models/components/constraintvalidation.md | 22 + docs/models/components/content.md | 12 +- .../components/createintegrationrequestdto.md | 2 +- .../createintegrationrequestdtochannel.md | 2 +- .../components/delayregularmetadataunit.md | 2 +- docs/models/components/digestmetadatadto.md | 26 +- .../components/digestmetadatadtounit.md | 17 + .../components/digestregularmetadata.md | 22 +- .../components/digestregularmetadatatype.md | 15 - .../components/digestregularmetadataunit.md | 15 - .../models/components/digesttimedconfigdto.md | 18 +- .../digesttimedconfigdtoweekdays.md | 15 + .../components/digesttimedmetadataunit.md | 2 +- docs/models/components/digesttypeenum.md | 2 +- docs/models/components/digestunitenum.md | 2 +- docs/models/components/emailblock.md | 2 +- .../components/executiondetailsstatusenum.md | 2 +- docs/models/components/feedresponsedto.md | 9 +- docs/models/components/fieldfilterpartdto.md | 2 +- .../{errors/value.md => components/five.md} | 14 +- docs/models/components/four.md | 14 + .../components/getsubscriberpreferencesdto.md | 26 +- docs/models/components/globalpreferencedto.md | 19 - .../components/integrationresponsedto.md | 4 +- .../integrationresponsedtochannel.md | 17 - .../components/listsubscribersresponsedto.md | 8 +- .../components/markmessageactionasseendto.md | 2 +- docs/models/components/messageactionresult.md | 8 +- .../components/messageactionresultpayload.md | 16 - docs/models/components/messagebutton.md | 2 +- docs/models/components/messagecta.md | 6 +- .../components/messagemarkasrequestdto.md | 4 +- .../messagemarkasrequestdtomarkas.md | 2 +- docs/models/components/messageresponsedto.md | 134 +- docs/models/components/messagesresponsedto.md | 112 + docs/models/components/metadata.md | 38 +- docs/models/components/monthlytype.md | 2 +- .../components/notificationfeeditemdto.md | 10 +- docs/models/components/notificationstepdto.md | 2 +- .../components/notificationstepdtometadata.md | 40 - .../components/notificationtriggerdto.md | 2 +- .../components/notificationtriggerdtotype.md | 17 + docs/models/components/on.md | 2 +- docs/models/components/operator.md | 2 +- docs/models/components/ordinal.md | 2 +- docs/models/components/ordinalenum.md | 2 +- docs/models/components/ordinalvalue.md | 2 +- docs/models/components/ordinalvalueenum.md | 2 +- docs/models/components/overrides.md | 20 +- .../patchsubscriberpreferencesdto.md | 8 +- docs/models/components/payload.md | 2 +- docs/models/components/preferencechannels.md | 19 - .../preferenceoverridesourceenum.md | 17 + docs/models/components/providerid.md | 4 +- docs/models/components/providersidenum.md | 4 +- docs/models/components/source.md | 17 - docs/models/components/status.md | 2 +- docs/models/components/stepfilterdto.md | 6 +- docs/models/components/stepfilterdtovalue.md | 15 + docs/models/components/stepsoverrides.md | 21 + docs/models/components/steptypeenum.md | 4 +- .../models/components/subscriberchanneldto.md | 12 +- .../subscriberchanneldtoproviderid.md | 17 - .../subscriberglobalpreferencedto.md | 25 + .../components/subscriberpayloaddtodata.md | 2 +- .../subscriberpreferencechannels.md | 25 + .../subscriberpreferenceoverridedto.md | 19 + ...> subscriberpreferencesworkflowinfodto.md} | 6 +- .../components/subscriberresponsedto.md | 18 +- .../subscriberworkflowpreferencedto.md | 38 + docs/models/components/textalignenum.md | 2 +- docs/models/components/timedconfig.md | 16 +- docs/models/components/timedconfigweekdays.md | 15 - docs/models/components/to.md | 4 +- docs/models/components/topicpayloaddto.md | 2 +- .../components/triggereventrequestdto.md | 14 +- .../components/triggereventresponsedto.md | 2 +- .../components/triggereventtoallrequestdto.md | 10 +- .../triggereventtoallrequestdtooverrides.md | 22 +- .../components/triggerrecipientstypeenum.md | 2 +- docs/models/components/type.md | 6 +- docs/models/components/unit.md | 4 +- docs/models/components/unseencountresponse.md | 2 +- .../updatesubscriberchannelrequestdto.md | 12 +- docs/models/components/value.md | 36 +- docs/models/components/weekdays.md | 2 +- docs/models/components/workfloworiginenum.md | 2 +- .../components/workflowpreferencedto.md | 32 - docs/models/components/workflowresponse.md | 57 +- docs/models/errors/errordto.md | 2 +- docs/models/errors/errors.md | 22 - docs/models/errors/five.md | 31 + docs/models/errors/four.md | 14 + docs/models/errors/message.md | 39 + docs/models/errors/message4.md | 14 + docs/models/errors/message5.md | 31 + docs/models/errors/validationerrordto.md | 18 +- .../errors/validationerrordtomessage.md | 39 + ...ntscontrollerbroadcasteventtoallrequest.md | 10 +- .../eventscontrollertriggerbulkrequest.md | 15 +- .../eventscontrollertriggerbulkresponse.md | 2 +- .../eventscontrollertriggerrequest.md | 8 +- .../eventscontrollertriggerresponse.md | 2 +- ...ionscontrollercreateintegrationresponse.md | 2 +- ...tionscontrollerlistintegrationsresponse.md | 2 +- ...ionscontrollerremoveintegrationresponse.md | 2 +- ...ntrollersetintegrationasprimaryresponse.md | 2 +- ...controllerupdateintegrationbyidresponse.md | 2 +- .../messagescontrollergetmessagesresponse.md | 102 +- ...controllergetactivitygraphstatsresponse.md | 4 +- ...tionscontrollergetactivitystatsresponse.md | 4 +- ...ationscontrollergetnotificationresponse.md | 44 +- ...ionscontrollerlistnotificationsresponse.md | 56 +- docs/models/operations/orderdirection.md | 2 +- ...iberscontrollercreatesubscriberresponse.md | 8 +- ...trollergetsubscriberpreferencesresponse.md | 20 +- ...scriberscontrollergetsubscriberresponse.md | 8 +- ...riberscontrollerpatchsubscriberresponse.md | 8 +- ...berscontrollersearchsubscribersresponse.md | 8 +- ...llerupdatesubscriberpreferencesresponse.md | 20 +- ...1controllergetnotificationsfeedresponse.md | 5 +- ...ibersv1controllergetunseencountresponse.md | 2 +- ...bersv1controllerlistsubscribersresponse.md | 12 +- ...v1controllerlistsubscribersresponsebody.md | 12 +- ...ersv1controllermarkactionasseenresponse.md | 62 +- ...sv1controllermarkallunreadasreadrequest.md | 2 +- ...v1controllermarkallunreadasreadresponse.md | 2 +- ...ribersv1controllermarkmessagesasrequest.md | 6 +- ...ibersv1controllermarkmessagesasresponse.md | 57 +- ...ontrollermodifysubscriberchannelrequest.md | 2 +- ...ntrollermodifysubscriberchannelresponse.md | 8 +- ...ontrollerupdatesubscriberchannelrequest.md | 2 +- ...ntrollerupdatesubscriberchannelresponse.md | 8 +- ...ollerupdatesubscriberonlineflagresponse.md | 8 +- ...ersv1controllerupdatesubscriberresponse.md | 8 +- docs/sdks/novu/README.md | 166 +- eslint.config.mjs | 1 + jsr.json | 2 +- package-lock.json | 8 +- package.json | 6 +- sources/code-samples.yaml | 6 +- sources/json-development.json | 2342 ++++++++++++++--- src/lib/config.ts | 8 +- src/lib/matchers.ts | 20 + src/lib/sdks.ts | 32 +- src/mcp-server/mcp-server.ts | 2 +- src/mcp-server/prompts.ts | 9 +- src/mcp-server/resources.ts | 18 +- src/mcp-server/server.ts | 6 +- src/mcp-server/tools.ts | 9 +- .../activitynotificationjobresponsedto.ts | 74 +- .../activitynotificationstepresponsedto.ts | 79 +- src/models/components/channelsettingsdto.ts | 58 +- .../components/chatorpushproviderenum.ts | 54 + src/models/components/constraintvalidation.ts | 270 ++ src/models/components/digestmetadatadto.ts | 31 +- .../components/digestregularmetadata.ts | 66 +- src/models/components/digesttimedconfigdto.ts | 32 +- .../components/getsubscriberpreferencesdto.ts | 36 +- src/models/components/globalpreferencedto.ts | 82 - src/models/components/index.ts | 15 +- .../components/integrationresponsedto.ts | 32 +- src/models/components/messageactionresult.ts | 55 +- src/models/components/messagecta.ts | 8 +- src/models/components/messageresponsedto.ts | 30 +- src/models/components/messagesresponsedto.ts | 103 + .../components/notificationfeeditemdto.ts | 7 - src/models/components/notificationstepdto.ts | 46 +- .../components/notificationtriggerdto.ts | 33 +- src/models/components/overrides.ts | 139 - .../patchsubscriberpreferencesdto.ts | 2 +- src/models/components/preferencechannels.ts | 91 - .../preferenceoverridesourceenum.ts | 42 + src/models/components/providersidenum.ts | 1 + src/models/components/stepfilterdto.ts | 31 +- src/models/components/stepsoverrides.ts | 65 + src/models/components/steptypeenum.ts | 4 +- src/models/components/subscriberchanneldto.ts | 32 +- .../subscriberglobalpreferencedto.ts | 84 + .../subscriberpreferencechannels.ts | 108 + .../subscriberpreferenceoverridedto.ts | 88 + .../subscriberpreferencesworkflowinfodto.ts | 95 + .../components/subscriberresponsedto.ts | 68 +- .../subscriberworkflowpreferencedto.ts | 110 + src/models/components/timedconfig.ts | 30 +- .../components/triggereventrequestdto.ts | 126 +- .../components/triggereventtoallrequestdto.ts | 97 +- .../updatesubscriberchannelrequestdto.ts | 64 +- src/models/components/workflowinfodto.ts | 88 - .../components/workflowpreferencedto.ts | 108 - src/models/components/workflowresponse.ts | 18 +- src/models/errors/errordto.ts | 207 +- src/models/errors/validationerrordto.ts | 288 +- .../messagescontrollergetmessages.ts | 8 +- 222 files changed, 6474 insertions(+), 3145 deletions(-) create mode 100644 docs/models/components/activitynotificationjobresponsedtopayload.md create mode 100644 docs/models/components/activitynotificationstepresponsedtometadata.md rename docs/models/components/{updatesubscriberchannelrequestdtoproviderid.md => chatorpushproviderenum.md} (61%) create mode 100644 docs/models/components/constraintvalidation.md create mode 100644 docs/models/components/digestmetadatadtounit.md delete mode 100644 docs/models/components/digestregularmetadatatype.md delete mode 100644 docs/models/components/digestregularmetadataunit.md create mode 100644 docs/models/components/digesttimedconfigdtoweekdays.md rename docs/models/{errors/value.md => components/five.md} (64%) create mode 100644 docs/models/components/four.md delete mode 100644 docs/models/components/globalpreferencedto.md delete mode 100644 docs/models/components/integrationresponsedtochannel.md delete mode 100644 docs/models/components/messageactionresultpayload.md create mode 100644 docs/models/components/messagesresponsedto.md delete mode 100644 docs/models/components/notificationstepdtometadata.md create mode 100644 docs/models/components/notificationtriggerdtotype.md delete mode 100644 docs/models/components/preferencechannels.md create mode 100644 docs/models/components/preferenceoverridesourceenum.md delete mode 100644 docs/models/components/source.md create mode 100644 docs/models/components/stepfilterdtovalue.md create mode 100644 docs/models/components/stepsoverrides.md delete mode 100644 docs/models/components/subscriberchanneldtoproviderid.md create mode 100644 docs/models/components/subscriberglobalpreferencedto.md create mode 100644 docs/models/components/subscriberpreferencechannels.md create mode 100644 docs/models/components/subscriberpreferenceoverridedto.md rename docs/models/components/{workflowinfodto.md => subscriberpreferencesworkflowinfodto.md} (84%) create mode 100644 docs/models/components/subscriberworkflowpreferencedto.md delete mode 100644 docs/models/components/timedconfigweekdays.md delete mode 100644 docs/models/components/workflowpreferencedto.md delete mode 100644 docs/models/errors/errors.md create mode 100644 docs/models/errors/five.md create mode 100644 docs/models/errors/four.md create mode 100644 docs/models/errors/message.md create mode 100644 docs/models/errors/message4.md create mode 100644 docs/models/errors/message5.md create mode 100644 docs/models/errors/validationerrordtomessage.md create mode 100644 src/models/components/chatorpushproviderenum.ts create mode 100644 src/models/components/constraintvalidation.ts delete mode 100644 src/models/components/globalpreferencedto.ts create mode 100644 src/models/components/messagesresponsedto.ts delete mode 100644 src/models/components/overrides.ts delete mode 100644 src/models/components/preferencechannels.ts create mode 100644 src/models/components/preferenceoverridesourceenum.ts create mode 100644 src/models/components/stepsoverrides.ts create mode 100644 src/models/components/subscriberglobalpreferencedto.ts create mode 100644 src/models/components/subscriberpreferencechannels.ts create mode 100644 src/models/components/subscriberpreferenceoverridedto.ts create mode 100644 src/models/components/subscriberpreferencesworkflowinfodto.ts create mode 100644 src/models/components/subscriberworkflowpreferencedto.ts delete mode 100644 src/models/components/workflowinfodto.ts delete mode 100644 src/models/components/workflowpreferencedto.ts diff --git a/.gitignore b/.gitignore index d12c7835..855bf21b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,7 @@ +.DS_Store +**/.speakeasy/temp/ +**/.speakeasy/logs/ +.DS_Store /mcp-server /bin /.eslintcache diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index 556bef4f..0318a93f 100644 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: 6bff3a53-3f0b-40b4-942f-ff70dc583ae5 management: - docChecksum: 01514c353e6680d2ea55fbd094e8f799 - docVersion: "1.0" - speakeasyVersion: 1.526.6 - generationVersion: 2.563.1 - releaseVersion: 0.6.2 - configChecksum: 5e859658ea8eafa5cb3bc7454e8f4008 + docChecksum: c3277e0b37e7507490de47e74f5f7650 + docVersion: 2.1.13 + speakeasyVersion: 1.542.3 + generationVersion: 2.597.9 + releaseVersion: 0.7.0 + configChecksum: 47a8899aa124ab205a891338697f0ff1 repoURL: https://github.com/novuhq/novu-ts.git installationURL: https://github.com/novuhq/novu-ts published: true @@ -14,8 +14,9 @@ features: typescript: acceptHeaders: 2.81.2 additionalDependencies: 0.1.0 + additionalProperties: 0.1.1 constsAndDefaults: 0.1.11 - core: 3.21.4 + core: 3.21.7 defaultEnabledRetries: 0.1.0 deprecations: 2.81.1 enumUnions: 0.1.0 @@ -27,7 +28,7 @@ features: globalSecurityFlattening: 0.1.0 globalServerURLs: 2.82.4 groups: 2.81.2 - mcpServer: 0.9.0 + mcpServer: 0.9.2 nameOverrides: 2.81.2 nullables: 0.1.1 pagination: 2.83.0 @@ -46,11 +47,13 @@ generatedFiles: - docs/models/components/activitygraphstatesresponse.md - docs/models/components/activitynotificationexecutiondetailresponsedto.md - docs/models/components/activitynotificationjobresponsedto.md + - docs/models/components/activitynotificationjobresponsedtopayload.md - docs/models/components/activitynotificationjobresponsedtotype.md - docs/models/components/activitynotificationresponsedto.md - docs/models/components/activitynotificationresponsedtopayload.md - docs/models/components/activitynotificationresponsedtoto.md - docs/models/components/activitynotificationstepresponsedto.md + - docs/models/components/activitynotificationstepresponsedtometadata.md - docs/models/components/activitynotificationstepresponsedtoreplycallback.md - docs/models/components/activitynotificationsubscriberresponsedto.md - docs/models/components/activitynotificationtemplateresponsedto.md @@ -73,6 +76,8 @@ generatedFiles: - docs/models/components/channels.md - docs/models/components/channelsettingsdto.md - docs/models/components/channeltypeenum.md + - docs/models/components/chatorpushproviderenum.md + - docs/models/components/constraintvalidation.md - docs/models/components/content.md - docs/models/components/controls.md - docs/models/components/controlvariables.md @@ -92,10 +97,10 @@ generatedFiles: - docs/models/components/deletemessageresponsedto.md - docs/models/components/deletemessageresponsedtostatus.md - docs/models/components/digestmetadatadto.md + - docs/models/components/digestmetadatadtounit.md - docs/models/components/digestregularmetadata.md - - docs/models/components/digestregularmetadatatype.md - - docs/models/components/digestregularmetadataunit.md - docs/models/components/digesttimedconfigdto.md + - docs/models/components/digesttimedconfigdtoweekdays.md - docs/models/components/digesttimedmetadata.md - docs/models/components/digesttimedmetadatatype.md - docs/models/components/digesttimedmetadataunit.md @@ -112,11 +117,11 @@ generatedFiles: - docs/models/components/feedresponsedto.md - docs/models/components/fieldfilterpartdto.md - docs/models/components/filtertopicsresponsedto.md + - docs/models/components/five.md + - docs/models/components/four.md - docs/models/components/getsubscriberpreferencesdto.md - docs/models/components/gettopicresponsedto.md - - docs/models/components/globalpreferencedto.md - docs/models/components/integrationresponsedto.md - - docs/models/components/integrationresponsedtochannel.md - docs/models/components/issues.md - docs/models/components/listsubscribersresponsedto.md - docs/models/components/markallmessageasrequestdto.md @@ -126,7 +131,6 @@ generatedFiles: - docs/models/components/markmessageactionasseendtostatus.md - docs/models/components/messageaction.md - docs/models/components/messageactionresult.md - - docs/models/components/messageactionresultpayload.md - docs/models/components/messageactionstatusenum.md - docs/models/components/messagebutton.md - docs/models/components/messagecta.md @@ -137,6 +141,7 @@ generatedFiles: - docs/models/components/messageresponsedto.md - docs/models/components/messageresponsedtooverrides.md - docs/models/components/messageresponsedtopayload.md + - docs/models/components/messagesresponsedto.md - docs/models/components/messagestatusenum.md - docs/models/components/messagetemplate.md - docs/models/components/messagetemplatedto.md @@ -149,9 +154,9 @@ generatedFiles: - docs/models/components/notificationstepdata.md - docs/models/components/notificationstepdatametadata.md - docs/models/components/notificationstepdto.md - - docs/models/components/notificationstepdtometadata.md - docs/models/components/notificationtrigger.md - docs/models/components/notificationtriggerdto.md + - docs/models/components/notificationtriggerdtotype.md - docs/models/components/notificationtriggertype.md - docs/models/components/notificationtriggervariable.md - docs/models/components/on.md @@ -166,7 +171,7 @@ generatedFiles: - docs/models/components/patchsubscriberpreferencesdto.md - docs/models/components/patchsubscriberrequestdto.md - docs/models/components/payload.md - - docs/models/components/preferencechannels.md + - docs/models/components/preferenceoverridesourceenum.md - docs/models/components/providerid.md - docs/models/components/providersidenum.md - docs/models/components/removesubscriberresponsedto.md @@ -175,22 +180,26 @@ generatedFiles: - docs/models/components/renametopicresponsedto.md - docs/models/components/replycallback.md - docs/models/components/security.md - - docs/models/components/source.md - docs/models/components/status.md - docs/models/components/stepfilterdto.md + - docs/models/components/stepfilterdtovalue.md + - docs/models/components/stepsoverrides.md - docs/models/components/steptypeenum.md - docs/models/components/subscriberchanneldto.md - - docs/models/components/subscriberchanneldtoproviderid.md - docs/models/components/subscriberfeedresponsedto.md + - docs/models/components/subscriberglobalpreferencedto.md - docs/models/components/subscriberpayloaddto.md - docs/models/components/subscriberpayloaddtodata.md + - docs/models/components/subscriberpreferencechannels.md + - docs/models/components/subscriberpreferenceoverridedto.md + - docs/models/components/subscriberpreferencesworkflowinfodto.md - docs/models/components/subscriberresponsedto.md + - docs/models/components/subscriberworkflowpreferencedto.md - docs/models/components/tenant.md - docs/models/components/tenantpayloaddto.md - docs/models/components/tenantpayloaddtodata.md - docs/models/components/textalignenum.md - docs/models/components/timedconfig.md - - docs/models/components/timedconfigweekdays.md - docs/models/components/tlsoptions.md - docs/models/components/to.md - docs/models/components/topicdto.md @@ -209,21 +218,22 @@ generatedFiles: - docs/models/components/updatedsubscriberdto.md - docs/models/components/updateintegrationrequestdto.md - docs/models/components/updatesubscriberchannelrequestdto.md - - docs/models/components/updatesubscriberchannelrequestdtoproviderid.md - docs/models/components/updatesubscriberonlineflagrequestdto.md - docs/models/components/updatesubscriberrequestdto.md - docs/models/components/value.md - docs/models/components/weekdays.md - - docs/models/components/workflowinfodto.md - docs/models/components/workflowintegrationstatus.md - docs/models/components/workfloworiginenum.md - - docs/models/components/workflowpreferencedto.md - docs/models/components/workflowresponse.md - docs/models/components/workflowresponsedata.md - docs/models/errors/errordto.md - - docs/models/errors/errors.md + - docs/models/errors/five.md + - docs/models/errors/four.md + - docs/models/errors/message.md + - docs/models/errors/message4.md + - docs/models/errors/message5.md - docs/models/errors/validationerrordto.md - - docs/models/errors/value.md + - docs/models/errors/validationerrordtomessage.md - docs/models/operations/channel.md - docs/models/operations/eventscontrollerbroadcasteventtoallrequest.md - docs/models/operations/eventscontrollerbroadcasteventtoallresponse.md @@ -490,6 +500,8 @@ generatedFiles: - src/models/components/channelctatypeenum.ts - src/models/components/channelsettingsdto.ts - src/models/components/channeltypeenum.ts + - src/models/components/chatorpushproviderenum.ts + - src/models/components/constraintvalidation.ts - src/models/components/createdsubscriberdto.ts - src/models/components/createintegrationrequestdto.ts - src/models/components/createsubscriberrequestdto.ts @@ -517,7 +529,6 @@ generatedFiles: - src/models/components/filtertopicsresponsedto.ts - src/models/components/getsubscriberpreferencesdto.ts - src/models/components/gettopicresponsedto.ts - - src/models/components/globalpreferencedto.ts - src/models/components/index.ts - src/models/components/integrationresponsedto.ts - src/models/components/listsubscribersresponsedto.ts @@ -531,6 +542,7 @@ generatedFiles: - src/models/components/messagectadata.ts - src/models/components/messagemarkasrequestdto.ts - src/models/components/messageresponsedto.ts + - src/models/components/messagesresponsedto.ts - src/models/components/messagestatusenum.ts - src/models/components/messagetemplate.ts - src/models/components/messagetemplatedto.ts @@ -544,11 +556,10 @@ generatedFiles: - src/models/components/notificationtriggervariable.ts - src/models/components/ordinalenum.ts - src/models/components/ordinalvalueenum.ts - - src/models/components/overrides.ts - src/models/components/patchpreferencechannelsdto.ts - src/models/components/patchsubscriberpreferencesdto.ts - src/models/components/patchsubscriberrequestdto.ts - - src/models/components/preferencechannels.ts + - src/models/components/preferenceoverridesourceenum.ts - src/models/components/providersidenum.ts - src/models/components/removesubscriberresponsedto.ts - src/models/components/removesubscribersrequestdto.ts @@ -557,11 +568,17 @@ generatedFiles: - src/models/components/replycallback.ts - src/models/components/security.ts - src/models/components/stepfilterdto.ts + - src/models/components/stepsoverrides.ts - src/models/components/steptypeenum.ts - src/models/components/subscriberchanneldto.ts - src/models/components/subscriberfeedresponsedto.ts + - src/models/components/subscriberglobalpreferencedto.ts - src/models/components/subscriberpayloaddto.ts + - src/models/components/subscriberpreferencechannels.ts + - src/models/components/subscriberpreferenceoverridedto.ts + - src/models/components/subscriberpreferencesworkflowinfodto.ts - src/models/components/subscriberresponsedto.ts + - src/models/components/subscriberworkflowpreferencedto.ts - src/models/components/tenantpayloaddto.ts - src/models/components/textalignenum.ts - src/models/components/timedconfig.ts @@ -578,9 +595,7 @@ generatedFiles: - src/models/components/updatesubscriberchannelrequestdto.ts - src/models/components/updatesubscriberonlineflagrequestdto.ts - src/models/components/updatesubscriberrequestdto.ts - - src/models/components/workflowinfodto.ts - src/models/components/workfloworiginenum.ts - - src/models/components/workflowpreferencedto.ts - src/models/components/workflowresponse.ts - src/models/errors/errordto.ts - src/models/errors/httpclienterrors.ts @@ -666,48 +681,18 @@ examples: EventsController_trigger: speakeasy-default-events-controller-trigger: requestBody: - application/json: {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"fcm": {"data": {"key": "value"}}}, "to": {"subscriberId": ""}} + application/json: {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"steps": {"email-step": {"providers": {"sendgrid": {"templateId": "1234567890"}}}}, "providers": {"sendgrid": {"templateId": "1234567890"}}}, "to": {"subscriberId": ""}} responses: "201": - application/json: {"acknowledged": false, "status": "processed"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - EventsController_triggerBulk: - speakeasy-default-events-controller-trigger-bulk: - requestBody: - application/json: {"events": [{"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"fcm": {"data": {"key": "value"}}}, "to": {"subscriberId": ""}}, {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"fcm": {"data": {"key": "value"}}}, "to": [{"topicKey": "", "type": "Subscriber"}]}, {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"fcm": {"data": {"key": "value"}}}, "to": ["SUBSCRIBER_ID", "SUBSCRIBER_ID"]}]} - responses: - "201": - application/json: [{"acknowledged": true, "status": "error"}, {"acknowledged": true, "status": "no_workflow_active_steps_defined"}, {"acknowledged": true, "status": "trigger_not_active"}] - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"acknowledged": false, "status": "no_tenant_found"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - EventsController_broadcastEventToAll: - speakeasy-default-events-controller-broadcast-event-to-all: - requestBody: - application/json: {"name": "", "payload": {"comment_id": "string", "post": {"text": "string"}}} - responses: - "200": - application/json: {"acknowledged": true, "status": "trigger_not_active"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} EventsController_cancel: speakeasy-default-events-controller-cancel: parameters: @@ -716,200 +701,128 @@ examples: header: {} responses: "200": - application/json: {"data": true} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: true "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SupportController_fetchUserOrganizations: - speakeasy-default-support-controller-fetch-user-organizations: - requestBody: - application/json: {"timestamp": ""} - responses: - "201": - application/json: {} - SupportController_createThread: - speakeasy-default-support-controller-create-thread: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + EventsController_broadcastEventToAll: + speakeasy-default-events-controller-broadcast-event-to-all: requestBody: - application/json: {"text": ""} - NotificationsController_listNotifications: - speakeasy-default-notifications-controller-list-notifications: - parameters: - query: - page: 0 - limit: 10 - header: {} + application/json: {"name": "", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"steps": {"email-step": {"providers": {"sendgrid": {"templateId": "1234567890"}}}}, "providers": {"sendgrid": {"templateId": "1234567890"}}, "fcm": {"data": {"key": "value"}}}} responses: "200": - application/json: {"hasMore": false, "data": [{"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "push", "executionDetails": [{"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": true, "providerId": "bandwidth", "source": "Payload"}, {"_id": "", "status": "Success", "detail": "", "isRetry": false, "isTest": true, "providerId": "nodemailer", "source": "Payload"}], "step": {"_id": "", "active": false, "filters": [{"isNegated": true, "type": "BOOLEAN", "value": "AND", "children": [{"field": "", "value": "", "operator": "SMALLER", "on": "payload"}]}, {"isNegated": false, "type": "GROUP", "value": "AND", "children": []}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "plivo", "status": ""}, {"_id": "", "type": "delay", "executionDetails": [], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "TEXT", "value": "AND", "children": [{"field": "", "value": "", "operator": "SMALLER", "on": "subscriber"}, {"field": "", "value": "", "operator": "NOT_EQUAL", "on": "subscriber"}, {"field": "", "value": "", "operator": "ALL_IN", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "maqsam", "status": ""}, {"_id": "", "type": "delay", "executionDetails": [{"_id": "", "status": "ReadConfirmation", "detail": "", "isRetry": true, "isTest": true, "providerId": "sendinblue", "source": "Credentials"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "bandwidth", "status": ""}]}, {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "custom", "executionDetails": [], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "MULTI_LIST", "value": "OR", "children": []}, {"isNegated": true, "type": "BOOLEAN", "value": "OR", "children": [{"field": "", "value": "", "operator": "SMALLER", "on": "payload"}, {"field": "", "value": "", "operator": "SMALLER_EQUAL", "on": "payload"}, {"field": "", "value": "", "operator": "ANY_IN", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "nodemailer", "status": ""}, {"_id": "", "type": "sms", "executionDetails": [{"_id": "", "status": "Queued", "detail": "", "isRetry": true, "isTest": true, "providerId": "sendgrid", "source": "Payload"}, {"_id": "", "status": "Failed", "detail": "", "isRetry": true, "isTest": false, "providerId": "getstream", "source": "Webhook"}, {"_id": "", "status": "Pending", "detail": "", "isRetry": false, "isTest": false, "providerId": "mailgun", "source": "Internal"}], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "NUMBER", "value": "AND", "children": [{"field": "", "value": "", "operator": "BETWEEN", "on": "payload"}, {"field": "", "value": "", "operator": "NOT_EQUAL", "on": "subscriber"}]}, {"isNegated": false, "type": "DATE", "value": "AND", "children": []}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "ses", "status": ""}, {"_id": "", "type": "custom", "executionDetails": [{"_id": "", "status": "Failed", "detail": "", "isRetry": true, "isTest": true, "providerId": "mailtrap", "source": "Webhook"}, {"_id": "", "status": "Success", "detail": "", "isRetry": false, "isTest": true, "providerId": "plunk", "source": "Credentials"}, {"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": false, "providerId": "pusher-beams", "source": "Internal"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "isend-sms", "status": ""}]}], "pageSize": 6783.17, "page": 1777.06} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"acknowledged": true, "status": "trigger_not_active"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - NotificationsController_getNotification: - speakeasy-default-notifications-controller-get-notification: - parameters: - path: - notificationId: "" - header: {} - responses: - "200": - application/json: {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "custom", "executionDetails": [{"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": false, "providerId": "azure-sms", "source": "Credentials"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "apns", "status": ""}, {"_id": "", "type": "custom", "executionDetails": [], "step": {"_id": "", "active": true, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "bandwidth", "status": ""}]} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - NotificationsController_getActivityStats: - speakeasy-default-notifications-controller-get-activity-stats: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + EventsController_triggerBulk: + speakeasy-default-events-controller-trigger-bulk: + requestBody: + application/json: {"events": [{"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"steps": {"email-step": {"providers": {"sendgrid": {"templateId": "1234567890"}}}}, "providers": {"sendgrid": {"templateId": "1234567890"}}}, "to": {"subscriberId": ""}}, {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"steps": {"email-step": {"providers": {"sendgrid": {"templateId": "1234567890"}}}}, "providers": {"sendgrid": {"templateId": "1234567890"}}}, "to": {"topicKey": "", "type": "Subscriber"}}, {"name": "workflow_identifier", "payload": {"comment_id": "string", "post": {"text": "string"}}, "overrides": {"steps": {"email-step": {"providers": {"sendgrid": {"templateId": "1234567890"}}}}, "providers": {"sendgrid": {"templateId": "1234567890"}}}, "to": ["SUBSCRIBER_ID", "SUBSCRIBER_ID"]}]} responses: - "200": - application/json: {"weeklySent": 3704.56, "monthlySent": 9198.31} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "201": + application/json: [{"acknowledged": true, "status": "error"}, {"acknowledged": true, "status": "no_workflow_active_steps_defined"}, {"acknowledged": true, "status": "trigger_not_active"}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - NotificationsController_getActivityGraphStats: - speakeasy-default-notifications-controller-get-activity-graph-stats: - responses: - "200": - application/json: [{"_id": "", "count": 4718.99, "templates": ["", "", ""], "channels": []}, {"_id": "", "count": 3081.94, "templates": ["", ""], "channels": ["email", "email"]}] + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_listIntegrations: - speakeasy-default-integrations-controller-list-integrations: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_searchSubscribers: + speakeasy-default-subscribers-controller-search-subscribers: responses: "200": - application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "sms", "credentials": {}, "active": false, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "in_app", "credentials": {}, "active": false, "deleted": false, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": true, "primary": false}] - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"data": [{"channels": [{"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "discord", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1722651307735", "updatedAt": "1746626532114"}], "next": "", "previous": ""} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_createIntegration: - speakeasy-default-integrations-controller-create-integration: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_createSubscriber: + speakeasy-default-subscribers-controller-create-subscriber: requestBody: - application/json: {"providerId": "", "channel": "sms"} + application/json: {"subscriberId": ""} responses: "201": - application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": true, "primary": true} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1717304408070", "updatedAt": "1746646023677"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_getActiveIntegrations: - speakeasy-default-integrations-controller-get-active-integrations: - responses: - "200": - application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "email", "credentials": {}, "active": true, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": false, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": false, "deleted": true, "primary": true}] + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_updateIntegrationById: - speakeasy-default-integrations-controller-update-integration-by-id: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_getSubscriber: + speakeasy-default-subscribers-controller-get-subscriber: parameters: path: - integrationId: "" + subscriberId: "" header: {} - requestBody: - application/json: {} responses: "200": - application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "push", "credentials": {}, "active": false, "deleted": true, "primary": false} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "push-webhook", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1717994727341", "updatedAt": "1746623474497"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_removeIntegration: - speakeasy-default-integrations-controller-remove-integration: - parameters: - path: - integrationId: "" - header: {} - responses: - "200": - application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": false, "primary": false}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": false, "primary": false}] + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_setIntegrationAsPrimary: - speakeasy-default-integrations-controller-set-integration-as-primary: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_patchSubscriber: + speakeasy-default-subscribers-controller-patch-subscriber: parameters: path: - integrationId: "" + subscriberId: "" header: {} + requestBody: + application/json: {} responses: "200": - application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "email", "credentials": {}, "active": false, "deleted": false, "primary": true} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1744384867410", "updatedAt": "1746632936945"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - IntegrationsController_getWebhookSupportStatus: - speakeasy-default-integrations-controller-get-webhook-support-status: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_removeSubscriber: + speakeasy-default-subscribers-controller-remove-subscriber: parameters: path: - providerOrIntegrationId: "" + subscriberId: "" header: {} responses: "200": - application/json: true - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"acknowledged": true, "status": "success"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_listSubscribers: - speakeasy-default-subscribers-controller-list-subscribers: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_listSubscribers: + speakeasy-default-subscribers-v1-controller-list-subscribers: parameters: query: limit: 10 @@ -917,102 +830,86 @@ examples: responses: "200": application/json: {"page": 7685.78, "hasMore": false, "pageSize": 6783.17, "data": []} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_createSubscriber: - speakeasy-default-subscribers-controller-create-subscriber: - requestBody: - application/json: {"subscriberId": ""} - responses: - "201": - application/json: {"subscriberId": "", "channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1708190069319", "updatedAt": "1737531684926"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1709571070797", "updatedAt": "1738912686405"} - SubscribersController_getSubscriber: - speakeasy-default-subscribers-controller-get-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_updateSubscriber: + speakeasy-default-subscribers-v1-controller-update-subscriber: parameters: path: subscriberId: "" - query: {} header: {} + requestBody: + application/json: {"email": "john.doe@example.com", "firstName": "John", "lastName": "Doe", "phone": "+1234567890", "avatar": "https://example.com/avatar.jpg", "locale": "en-US", "data": {"preferences": {"notifications": true, "theme": "dark"}, "tags": ["premium", "newsletter"]}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "push-webhook", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1708880388588", "updatedAt": "1737509135744"} + application/json: {"channels": [{"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "grafana-on-call", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1722446091647", "updatedAt": "1746643471846"} + "414": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "422": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + "500": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_bulkCreateSubscribers: + speakeasy-default-subscribers-v1-controller-bulk-create-subscribers: + requestBody: + application/json: {"subscribers": [{"subscriberId": ""}]} + responses: + "201": + application/json: {"updated": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "created": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "failed": [{}, {}]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriber: - speakeasy-default-subscribers-controller-update-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_getSubscriberPreferences: + speakeasy-default-subscribers-controller-get-subscriber-preferences: parameters: path: subscriberId: "" header: {} - requestBody: - application/json: {"email": "john.doe@example.com", "firstName": "John", "lastName": "Doe", "phone": "+1234567890", "avatar": "https://example.com/avatar.jpg", "locale": "en-US", "data": {"preferences": {"notifications": true, "theme": "dark"}, "tags": ["premium", "newsletter"]}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1721429716849", "updatedAt": "1737547887655"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"global": {"enabled": false, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}}, "workflows": [{"enabled": false, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}, {"enabled": true, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_removeSubscriber: - speakeasy-default-subscribers-controller-remove-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersController_updateSubscriberPreferences: + speakeasy-default-subscribers-controller-update-subscriber-preferences: parameters: path: subscriberId: "" header: {} + requestBody: + application/json: {"channels": {}} responses: "200": - application/json: {"acknowledged": true, "status": "success"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"global": {"enabled": false, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}}, "workflows": [{"enabled": true, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "overrides": [{"channel": "chat", "source": "template"}, {"channel": "push", "source": "subscriber"}, {"channel": "push", "source": "template"}], "workflow": {"slug": "", "identifier": "", "name": ""}}, {"enabled": true, "channels": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_bulkCreateSubscribers: - speakeasy-default-subscribers-controller-bulk-create-subscribers: - requestBody: - application/json: {"subscribers": [{"subscriberId": ""}]} - responses: - "201": - application/json: {"updated": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "created": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "failed": [{}, {}]} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriberChannel: - speakeasy-default-subscribers-controller-update-subscriber-channel: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_updateSubscriberChannel: + speakeasy-default-subscribers-v1-controller-update-subscriber-channel: parameters: path: subscriberId: "" @@ -1021,17 +918,17 @@ examples: application/json: {"providerId": "pushpad", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1721429716906", "updatedAt": "1737547887712"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1730544055808", "updatedAt": "1746662226614"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_modifySubscriberChannel: - speakeasy-default-subscribers-controller-modify-subscriber-channel: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_modifySubscriberChannel: + speakeasy-default-subscribers-v1-controller-modify-subscriber-channel: parameters: path: subscriberId: "" @@ -1040,127 +937,134 @@ examples: application/json: {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "pushpad", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "apns", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1737460724203", "updatedAt": "1737510674584"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "pushpad", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "apns", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1746575063107", "updatedAt": "1746625013488"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_deleteSubscriberCredentials: - speakeasy-default-subscribers-controller-delete-subscriber-credentials: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_deleteSubscriberCredentials: + speakeasy-default-subscribers-v1-controller-delete-subscriber-credentials: parameters: path: subscriberId: "" providerId: "" header: {} responses: - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriberOnlineFlag: - speakeasy-default-subscribers-controller-update-subscriber-online-flag: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_chatAccessOauth: + speakeasy-default-subscribers-v1-controller-chat-access-oauth: parameters: path: subscriberId: "" + providerId: "" + query: + hmacHash: "" + environmentId: "" header: {} - requestBody: - application/json: {"isOnline": false} responses: - "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "one-signal", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1732483151500", "updatedAt": "1737479755890"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_listSubscriberPreferences: - speakeasy-default-subscribers-controller-list-subscriber-preferences: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_chatOauthCallback: + speakeasy-default-subscribers-v1-controller-chat-oauth-callback: parameters: path: subscriberId: "" - query: {} + providerId: "" + query: + hmacHash: "" + environmentId: "" + code: "" header: {} responses: "200": - application/json: [{"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": []}, {"type": "event", "identifier": "", "variables": []}]}, "preference": {"enabled": true, "channels": {}}}, {"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": []}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}]}, "preference": {"enabled": true, "channels": {}}}, {"template": {"_id": "", "name": "", "critical": true, "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}]}, "preference": {"enabled": true, "channels": {}}}] - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + text/html: "" + "302": + application/json: "" "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriberGlobalPreferences: - speakeasy-default-subscribers-controller-update-subscriber-global-preferences: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_markActionAsSeen: + speakeasy-default-subscribers-v1-controller-mark-action-as-seen: parameters: path: + messageId: "" + type: "" subscriberId: "" header: {} requestBody: - application/json: {} + application/json: {"status": "done"} responses: - "200": - application/json: {"preference": {"enabled": true, "channels": {}}} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "201": + application/json: {"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"channels": [{"providerId": "push-webhook", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1745600575743", "updatedAt": "1746590542445"}, "template": {"name": "", "description": "after ouch meager stupendous failing", "active": false, "draft": false, "preferenceSettings": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "critical": true, "tags": ["", "", ""], "steps": [{}], "_organizationId": "", "_creatorId": "", "_environmentId": "", "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}, {"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}], "_notificationGroupId": "", "deleted": false, "deletedAt": "", "deletedBy": ""}, "createdAt": "1746196665325", "content": [{"type": "button", "content": ""}], "transactionId": "", "channel": "sms", "read": false, "seen": false, "cta": {}, "status": "error"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_getSubscriberPreferenceByLevel: - speakeasy-default-subscribers-controller-get-subscriber-preference-by-level: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_markAllUnreadAsRead: + speakeasy-default-subscribers-v1-controller-mark-all-unread-as-read: parameters: path: - parameter: "template" subscriberId: "" - query: {} header: {} + requestBody: + application/json: {"markAs": "seen"} responses: - "200": - application/json: [{"preference": {"enabled": true, "channels": {}}}, {"preference": {"enabled": true, "channels": {}}}] - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "201": + application/json: 4603.37 "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriberPreference: - speakeasy-default-subscribers-controller-update-subscriber-preference: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_markMessagesAs: + speakeasy-default-subscribers-v1-controller-mark-messages-as: parameters: path: subscriberId: "" - parameter: "" header: {} requestBody: - application/json: {} + application/json: {"messageId": "", "markAs": "unread"} responses: - "200": - application/json: {"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}, {"name": ""}]}]}, "preference": {"enabled": false, "channels": {}}} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "201": + application/json: [{"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"channels": [{"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1733175265982", "updatedAt": "1746645328395"}, "template": {"name": "", "description": "deck instantly ultimately whenever stealthily pish ordinary microblog", "active": true, "draft": false, "preferenceSettings": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "critical": true, "tags": [""], "steps": [{}, {}, {}], "_organizationId": "", "_creatorId": "", "_environmentId": "", "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}]}, {"type": "event", "identifier": "", "variables": []}, {"type": "event", "identifier": "", "variables": []}], "_notificationGroupId": "", "deleted": false, "deletedAt": "", "deletedBy": ""}, "createdAt": "1720270583950", "content": "", "transactionId": "", "channel": "push", "read": true, "seen": true, "cta": {}, "status": "warning"}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_getNotificationsFeed: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_getNotificationsFeed: "": parameters: path: @@ -1171,17 +1075,17 @@ examples: header: {} responses: "200": - application/json: {"totalCount": 5, "hasMore": true, "data": [{"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "in_app", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}], "pageSize": 2, "page": 1} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"totalCount": 5, "hasMore": true, "data": [{"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deviceTokens": ["token1", "token2"], "cta": {}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deviceTokens": ["token1", "token2"], "cta": {}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "in_app", "read": false, "seen": true, "deviceTokens": ["token1", "token2"], "cta": {}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}], "pageSize": 2, "page": 1} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Must be a valid email address"], "value": "invalidEmail"}, "fieldName2": {"messages": ["Must be at least 18 years old"], "value": 17}, "fieldName3": {"messages": ["Must be a boolean value"], "value": true}, "fieldName4": {"messages": ["Must be a valid object"], "value": {"key": "value"}}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Must be a valid email address"], "value": "invalidEmail"}, "fieldName2": {"messages": ["Must be at least 18 years old"], "value": 17}, "fieldName3": {"messages": ["Must be a boolean value"], "value": true}, "fieldName4": {"messages": ["Must be a valid object"], "value": [{"key": "value"}]}, "fieldName5": {"messages": ["Field is missing"], "value": null}, "fieldName6": {"messages": ["Undefined value"]}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_getUnseenCount: - speakeasy-default-subscribers-controller-get-unseen-count: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_getUnseenCount: + speakeasy-default-subscribers-v1-controller-get-unseen-count: parameters: path: subscriberId: "" @@ -1192,767 +1096,396 @@ examples: responses: "200": application/json: {"count": 2166.35} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + "400": + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_markMessagesAs: - speakeasy-default-subscribers-controller-mark-messages-as: - parameters: - path: - subscriberId: "" - header: {} - requestBody: - application/json: {"messageId": "", "markAs": "unread"} - responses: - "201": - application/json: [{"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"subscriberId": "", "channels": [{"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1724060927125", "updatedAt": "1737530989538"}, "createdAt": "1727359970915", "content": {"type": "button", "content": ""}, "transactionId": "", "channel": "email", "read": false, "seen": true, "cta": {"data": {}}, "status": "error"}] - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_markAllUnreadAsRead: - speakeasy-default-subscribers-controller-mark-all-unread-as-read: - parameters: - path: - subscriberId: "" - header: {} - requestBody: - application/json: {"markAs": "seen"} - responses: - "201": - application/json: 4603.37 - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_markActionAsSeen: - speakeasy-default-subscribers-controller-mark-action-as-seen: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + SubscribersV1Controller_updateSubscriberOnlineFlag: + speakeasy-default-subscribers-v1-controller-update-subscriber-online-flag: parameters: path: - messageId: "" - type: "" subscriberId: "" header: {} requestBody: - application/json: {"status": "done"} - responses: - "201": - application/json: {"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"subscriberId": "", "channels": [{"providerId": "push-webhook", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1736486236979", "updatedAt": "1737476203680"}, "createdAt": "1714068779677", "content": {"type": "text", "content": ""}, "transactionId": "", "channel": "sms", "read": true, "seen": true, "cta": {"data": {}}, "status": "sent"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_chatOauthCallback: - speakeasy-default-subscribers-controller-chat-oauth-callback: - parameters: - path: - subscriberId: "" - providerId: "" - query: - hmacHash: "" - environmentId: "" - code: "" - header: {} + application/json: {"isOnline": false} responses: "200": - text/html: "" - "302": - application/json: "" - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_chatAccessOauth: - speakeasy-default-subscribers-controller-chat-access-oauth: - parameters: - path: - subscriberId: "" - providerId: "" - query: - hmacHash: "" - environmentId: "" - header: {} - responses: - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"channels": [{"providerId": "one-signal", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1741597490579", "updatedAt": "1746594094969"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - MessagesController_getMessages: - speakeasy-default-messages-controller-get-messages: - parameters: - query: - page: 0 - limit: 10 - header: {} - responses: - "200": - application/json: {"hasMore": true, "data": [{"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "custom", "executionDetails": [{"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": false, "providerId": "azure-sms", "source": "Credentials"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "apns", "status": ""}, {"_id": "", "type": "custom", "executionDetails": [], "step": {"_id": "", "active": true, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "bandwidth", "status": ""}]}, {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "in_app", "executionDetails": [{"_id": "", "status": "Success", "detail": "", "isRetry": true, "isTest": false, "providerId": "msteams", "source": "Payload"}], "step": {"_id": "", "active": true, "filters": [{"isNegated": false, "type": "STATEMENT", "value": "OR", "children": [{"field": "", "value": "", "operator": "NOT_EQUAL", "on": "payload"}, {"field": "", "value": "", "operator": "ANY_IN", "on": "payload"}]}, {"isNegated": false, "type": "LIST", "value": "OR", "children": [{"field": "", "value": "", "operator": "LARGER_EQUAL", "on": "subscriber"}, {"field": "", "value": "", "operator": "LARGER_EQUAL", "on": "subscriber"}, {"field": "", "value": "", "operator": "IN", "on": "payload"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "braze", "status": ""}, {"_id": "", "type": "push", "executionDetails": [], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "MULTI_LIST", "value": "AND", "children": [{"field": "", "value": "", "operator": "NOT_EQUAL", "on": "payload"}, {"field": "", "value": "", "operator": "NOT_LIKE", "on": "payload"}, {"field": "", "value": "", "operator": "ANY_IN", "on": "payload"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "messagebird", "status": ""}]}, {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "email", "executionDetails": [], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "LIST", "value": "AND", "children": []}, {"isNegated": false, "type": "LIST", "value": "OR", "children": []}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "nexmo", "status": ""}, {"_id": "", "type": "trigger", "executionDetails": [{"_id": "", "status": "ReadConfirmation", "detail": "", "isRetry": false, "isTest": true, "providerId": "push-webhook", "source": "Webhook"}, {"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": false, "providerId": "postmark", "source": "Internal"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "infobip-sms", "status": ""}, {"_id": "", "type": "email", "executionDetails": [{"_id": "", "status": "Warning", "detail": "", "isRetry": false, "isTest": true, "providerId": "termii", "source": "Payload"}], "step": {"_id": "", "active": false, "filters": [{"isNegated": true, "type": "LIST", "value": "AND", "children": [{"field": "", "value": "", "operator": "NOT_IN", "on": "subscriber"}, {"field": "", "value": "", "operator": "EQUAL", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "novu", "status": ""}]}], "pageSize": 3129.93, "page": 3234.02} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - MessagesController_deleteMessage: - speakeasy-default-messages-controller-delete-message: - parameters: - path: - messageId: "" - header: {} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_listIntegrations: + speakeasy-default-integrations-controller-list-integrations: responses: "200": - application/json: {"acknowledged": false, "status": "deleted"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "sms", "credentials": {}, "active": false, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "in_app", "credentials": {}, "active": false, "deleted": false, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": true, "primary": false}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - MessagesController_deleteMessagesByTransactionId: - speakeasy-default-messages-controller-delete-messages-by-transaction-id: - parameters: - path: - transactionId: "" - query: {} - header: {} - responses: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_createTopic: - speakeasy-default-topics-controller-create-topic: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_createIntegration: + speakeasy-default-integrations-controller-create-integration: requestBody: - application/json: {"key": "", "name": ""} + application/json: {"providerId": "", "channel": "sms"} responses: "201": - application/json: {"key": ""} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_listTopics: - "": - parameters: - query: - page: 0 - pageSize: 10 - key: "exampleKey" - header: {} - responses: - "200": - application/json: {"data": [], "page": 1, "pageSize": 10, "totalCount": 10} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Must be a valid email address"], "value": "invalidEmail"}, "fieldName2": {"messages": ["Must be at least 18 years old"], "value": 17}, "fieldName3": {"messages": ["Must be a boolean value"], "value": true}, "fieldName4": {"messages": ["Must be a valid object"], "value": {"key": "value"}}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_deleteTopic: - speakeasy-default-topics-controller-delete-topic: - parameters: - path: - topicKey: "" - header: {} - responses: - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_getTopic: - speakeasy-default-topics-controller-get-topic: - parameters: - path: - topicKey: "" - header: {} - responses: - "200": - application/json: {"_organizationId": "", "_environmentId": "", "key": "", "name": "", "subscribers": [""]} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_renameTopic: - speakeasy-default-topics-controller-rename-topic: - parameters: - path: - topicKey: "" - header: {} - requestBody: - application/json: {"name": ""} - responses: - "200": - application/json: {"_organizationId": "", "_environmentId": "", "key": "", "name": "", "subscribers": ["", "", ""]} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_assign: - speakeasy-default-topics-controller-assign: - parameters: - path: - topicKey: "" - header: {} - requestBody: - application/json: {"subscribers": ["", "", ""]} - responses: - "200": - application/json: {"succeeded": []} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": true, "primary": true} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_getTopicSubscriber: - speakeasy-default-topics-controller-get-topic-subscriber: - parameters: - path: - externalSubscriberId: "" - topicKey: "" - header: {} - responses: - "200": - application/json: {"_organizationId": "org_123456789", "_environmentId": "env_123456789", "_subscriberId": "sub_123456789", "_topicId": "topic_123456789", "topicKey": "my_topic_key", "externalSubscriberId": "external_subscriber_123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - TopicsController_removeSubscribers: - speakeasy-default-topics-controller-remove-subscribers: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_updateIntegrationById: + speakeasy-default-integrations-controller-update-integration-by-id: parameters: path: - topicKey: "" - header: {} - requestBody: - application/json: {"subscribers": ["", ""]} - responses: - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_listSubscribers: - speakeasy-default-subscribers-v1-controller-list-subscribers: - parameters: - query: - limit: 10 + integrationId: "" header: {} - responses: - "200": - application/json: {"page": 7685.78, "hasMore": false, "pageSize": 6783.17, "data": []} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_createSubscriber: - speakeasy-default-subscribers-v1-controller-create-subscriber: requestBody: - application/json: {"subscriberId": ""} - responses: - "201": - application/json: {"subscriberId": "", "channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1708934920145", "updatedAt": "1738276535752"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_getSubscriber: - speakeasy-default-subscribers-v1-controller-get-subscriber: - parameters: - path: - subscriberId: "" - query: {} - header: {} + application/json: {} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "expo", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "expo", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1727658113165", "updatedAt": "1738289711499"} + application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "push", "credentials": {}, "active": false, "deleted": true, "primary": false} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_updateSubscriber: - speakeasy-default-subscribers-v1-controller-update-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_removeIntegration: + speakeasy-default-integrations-controller-remove-integration: parameters: path: - subscriberId: "" + integrationId: "" header: {} - requestBody: - application/json: {"email": "john.doe@example.com", "firstName": "John", "lastName": "Doe", "phone": "+1234567890", "avatar": "https://example.com/avatar.jpg", "locale": "en-US", "data": {"preferences": {"notifications": true, "theme": "dark"}, "tags": ["premium", "newsletter"]}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1722174567656", "updatedAt": "1738292738462"} + application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": false, "primary": false}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": true, "deleted": false, "primary": false}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_removeSubscriber: - speakeasy-default-subscribers-v1-controller-remove-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_setIntegrationAsPrimary: + speakeasy-default-integrations-controller-set-integration-as-primary: parameters: path: - subscriberId: "" + integrationId: "" header: {} responses: "200": - application/json: {"acknowledged": false, "status": "deleted"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_bulkCreateSubscribers: - speakeasy-default-subscribers-v1-controller-bulk-create-subscribers: - requestBody: - application/json: {"subscribers": [{"subscriberId": ""}]} - responses: - "201": - application/json: {"updated": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "created": [{"subscriberId": ""}, {"subscriberId": ""}, {"subscriberId": ""}], "failed": [{}, {}]} + application/json: {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "email", "credentials": {}, "active": false, "deleted": false, "primary": true} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_searchSubscribers: - speakeasy-default-subscribers-controller-search-subscribers: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_getActiveIntegrations: + speakeasy-default-integrations-controller-get-active-integrations: responses: "200": - application/json: {"data": [{"subscriberId": "", "channels": [{"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "discord", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1714281819886", "updatedAt": "1738257044265"}], "next": "", "previous": ""} + application/json: [{"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "email", "credentials": {}, "active": true, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": false, "deleted": true, "primary": true}, {"_environmentId": "", "_organizationId": "", "name": "", "identifier": "", "providerId": "", "channel": "chat", "credentials": {}, "active": false, "deleted": true, "primary": true}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_patchSubscriber: - speakeasy-default-subscribers-controller-patch-subscriber: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + IntegrationsController_getWebhookSupportStatus: + speakeasy-default-integrations-controller-get-webhook-support-status: parameters: path: - subscriberId: "" + providerOrIntegrationId: "" header: {} - requestBody: - application/json: {} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "getstream", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1736015379513", "updatedAt": "1738263449048"} + application/json: true "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_updateSubscriberChannel: - speakeasy-default-subscribers-v1-controller-update-subscriber-channel: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + MessagesController_getMessages: + speakeasy-default-messages-controller-get-messages: parameters: - path: - subscriberId: "" + query: + page: 0 + limit: 10 header: {} - requestBody: - application/json: {"providerId": "pushpad", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1722174567727", "updatedAt": "1738292738533"} + application/json: {"hasMore": true, "data": [{"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"channels": [{"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1732014661869", "updatedAt": "1746635055230"}, "template": {"name": "", "description": "blissfully ouch pleasing serpentine", "active": false, "draft": false, "preferenceSettings": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "critical": true, "tags": [], "steps": [], "_organizationId": "", "_creatorId": "", "_environmentId": "", "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}, {"name": ""}]}], "_notificationGroupId": "", "deleted": false, "deletedAt": "", "deletedBy": ""}, "createdAt": "1724664708826", "content": [], "transactionId": "", "channel": "sms", "read": true, "seen": false, "cta": {}, "status": "warning"}, {"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"channels": [{"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1743621093975", "updatedAt": "1746656789495"}, "template": {"name": "", "description": "seriously till needy as cripple phooey deceivingly", "active": false, "draft": true, "preferenceSettings": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "critical": true, "tags": [], "steps": [], "_organizationId": "", "_creatorId": "", "_environmentId": "", "triggers": [], "_notificationGroupId": "", "deleted": false, "deletedAt": "", "deletedBy": ""}, "createdAt": "1738532552190", "content": [{"type": "text", "content": ""}, {"type": "button", "content": ""}, {"type": "text", "content": ""}], "transactionId": "", "channel": "in_app", "read": false, "seen": false, "cta": {}, "status": "error"}, {"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"channels": [{"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "fcm", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "subscriberId": "", "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1746259856345", "updatedAt": "1746607335766"}, "template": {"name": "", "description": "what yahoo positively gadzooks and turbulent tremendously", "active": false, "draft": true, "preferenceSettings": {"email": true, "sms": false, "in_app": true, "chat": false, "push": true}, "critical": false, "tags": [""], "steps": [{}, {}, {}], "_organizationId": "", "_creatorId": "", "_environmentId": "", "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}]}], "_notificationGroupId": "", "deleted": false, "deletedAt": "", "deletedBy": ""}, "createdAt": "1734551248743", "content": [{"type": "button", "content": ""}, {"type": "button", "content": ""}, {"type": "text", "content": ""}], "transactionId": "", "channel": "sms", "read": true, "seen": true, "cta": {}, "status": "warning"}], "pageSize": 4672.69, "page": 7638.04} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_modifySubscriberChannel: - speakeasy-default-subscribers-v1-controller-modify-subscriber-channel: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + MessagesController_deleteMessage: + speakeasy-default-messages-controller-delete-message: parameters: path: - subscriberId: "" + messageId: "" header: {} - requestBody: - application/json: {"providerId": "zulip", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "pushpad", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "apns", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1738205575014", "updatedAt": "1738255525395"} + application/json: {"acknowledged": false, "status": "deleted"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_deleteSubscriberCredentials: - speakeasy-default-subscribers-v1-controller-delete-subscriber-credentials: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + MessagesController_deleteMessagesByTransactionId: + speakeasy-default-messages-controller-delete-messages-by-transaction-id: parameters: path: - subscriberId: "" - providerId: "" + transactionId: "" + query: {} header: {} responses: "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_updateSubscriberOnlineFlag: - speakeasy-default-subscribers-v1-controller-update-subscriber-online-flag: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + NotificationsController_listNotifications: + speakeasy-default-notifications-controller-list-notifications: parameters: - path: - subscriberId: "" + query: + page: 0 + limit: 10 header: {} - requestBody: - application/json: {"isOnline": false} responses: "200": - application/json: {"subscriberId": "", "channels": [{"providerId": "one-signal", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "mattermost", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": false, "createdAt": "1733228002311", "updatedAt": "1738224606701"} + application/json: {"hasMore": false, "data": [{"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "email", "executionDetails": [], "step": {"_id": "", "active": true, "filters": [{"isNegated": false, "type": "BOOLEAN", "value": "OR", "children": []}, {"isNegated": true, "type": "LIST", "value": "OR", "children": [{"field": "", "value": "", "operator": "LARGER", "on": "subscriber"}, {"field": "", "value": "", "operator": "NOT_EQUAL", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "postmark", "status": ""}, {"_id": "", "type": "custom", "executionDetails": [{"_id": "", "status": "ReadConfirmation", "detail": "", "isRetry": true, "isTest": true, "providerId": "plivo", "source": "Webhook"}, {"_id": "", "status": "Success", "detail": "", "isRetry": false, "isTest": true, "providerId": "mattermost", "source": "Credentials"}], "step": {"_id": "", "active": true, "filters": [{"isNegated": true, "type": "NUMBER", "value": "AND", "children": [{"field": "", "value": "", "operator": "ALL_IN", "on": "subscriber"}]}, {"isNegated": false, "type": "MULTI_LIST", "value": "AND", "children": [{"field": "", "value": "", "operator": "EQUAL", "on": "subscriber"}, {"field": "", "value": "", "operator": "SMALLER", "on": "subscriber"}, {"field": "", "value": "", "operator": "NOT_LIKE", "on": "subscriber"}]}, {"isNegated": false, "type": "GROUP", "value": "OR", "children": []}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "brevo-sms", "status": ""}, {"_id": "", "type": "digest", "executionDetails": [{"_id": "", "status": "Queued", "detail": "", "isRetry": false, "isTest": true, "providerId": "resend", "source": "Credentials"}, {"_id": "", "status": "ReadConfirmation", "detail": "", "isRetry": false, "isTest": true, "providerId": "azure-sms", "source": "Internal"}, {"_id": "", "status": "Queued", "detail": "", "isRetry": false, "isTest": true, "providerId": "nodemailer", "source": "Internal"}], "step": {"_id": "", "active": false, "filters": [{"isNegated": true, "type": "DATE", "value": "AND", "children": [{"field": "", "value": "", "operator": "ALL_IN", "on": "subscriber"}, {"field": "", "value": "", "operator": "LIKE", "on": "payload"}]}, {"isNegated": false, "type": "STATEMENT", "value": "OR", "children": [{"field": "", "value": "", "operator": "LARGER", "on": "subscriber"}, {"field": "", "value": "", "operator": "IN", "on": "payload"}, {"field": "", "value": "", "operator": "NOT_BETWEEN", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "mailjet", "status": ""}]}, {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "trigger", "executionDetails": [{"_id": "", "status": "Failed", "detail": "", "isRetry": true, "isTest": false, "providerId": "sms77", "source": "Internal"}, {"_id": "", "status": "Success", "detail": "", "isRetry": true, "isTest": false, "providerId": "whatsapp-business", "source": "Internal"}], "step": {"_id": "", "active": true, "filters": [{"isNegated": true, "type": "GROUP", "value": "AND", "children": [{"field": "", "value": "", "operator": "NOT_EQUAL", "on": "subscriber"}, {"field": "", "value": "", "operator": "LARGER_EQUAL", "on": "subscriber"}]}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "ses", "status": ""}, {"_id": "", "type": "trigger", "executionDetails": [{"_id": "", "status": "Failed", "detail": "", "isRetry": false, "isTest": true, "providerId": "forty-six-elks", "source": "Webhook"}, {"_id": "", "status": "Queued", "detail": "", "isRetry": true, "isTest": false, "providerId": "sendinblue", "source": "Payload"}, {"_id": "", "status": "Pending", "detail": "", "isRetry": true, "isTest": true, "providerId": "clicksend", "source": "Internal"}], "step": {"_id": "", "active": false, "filters": [{"isNegated": false, "type": "STATEMENT", "value": "AND", "children": [{"field": "", "value": "", "operator": "BETWEEN", "on": "subscriber"}]}, {"isNegated": false, "type": "STATEMENT", "value": "OR", "children": []}], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "plunk", "status": ""}]}], "pageSize": 2139.89, "page": 3875.74} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_listSubscriberPreferences: - speakeasy-default-subscribers-v1-controller-list-subscriber-preferences: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + NotificationsController_getNotification: + speakeasy-default-notifications-controller-get-notification: parameters: path: - subscriberId: "" - query: {} + notificationId: "" header: {} responses: "200": - application/json: [{"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": []}, {"type": "event", "identifier": "", "variables": []}]}, "preference": {"enabled": true, "channels": {}}}, {"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": []}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}]}, "preference": {"enabled": true, "channels": {}}}, {"template": {"_id": "", "name": "", "critical": true, "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}]}]}, "preference": {"enabled": true, "channels": {}}}] + application/json: {"_environmentId": "", "_organizationId": "", "_subscriberId": "", "transactionId": "", "jobs": [{"_id": "", "type": "custom", "executionDetails": [{"_id": "", "status": "Warning", "detail": "", "isRetry": true, "isTest": false, "providerId": "azure-sms", "source": "Credentials"}], "step": {"_id": "", "active": false, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "apns", "status": ""}, {"_id": "", "type": "custom", "executionDetails": [], "step": {"_id": "", "active": true, "filters": [], "_templateId": ""}, "overrides": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "providerId": "messagebird", "status": ""}]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_updateSubscriberGlobalPreferences: - speakeasy-default-subscribers-v1-controller-update-subscriber-global-preferences: - parameters: - path: - subscriberId: "" - header: {} - requestBody: - application/json: {} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + NotificationsController_getActivityGraphStats: + speakeasy-default-notifications-controller-get-activity-graph-stats: responses: "200": - application/json: {"preference": {"enabled": true, "channels": {}}} + application/json: [{"_id": "", "count": 4718.99, "templates": ["", "", ""], "channels": []}, {"_id": "", "count": 3081.94, "templates": ["", ""], "channels": ["email", "email"]}] "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_getSubscriberPreferenceByLevel: - speakeasy-default-subscribers-v1-controller-get-subscriber-preference-by-level: - parameters: - path: - parameter: "template" - subscriberId: "" - query: {} - header: {} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + NotificationsController_getActivityStats: + speakeasy-default-notifications-controller-get-activity-stats: responses: "200": - application/json: [{"preference": {"enabled": true, "channels": {}}}, {"preference": {"enabled": true, "channels": {}}}] + application/json: {"weeklySent": 3704.56, "monthlySent": 9198.31} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_updateSubscriberPreference: - speakeasy-default-subscribers-v1-controller-update-subscriber-preference: - parameters: - path: - subscriberId: "" - parameter: "" - header: {} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_createTopic: + speakeasy-default-topics-controller-create-topic: requestBody: - application/json: {} + application/json: {"key": "", "name": ""} responses: - "200": - application/json: {"template": {"_id": "", "name": "", "critical": false, "triggers": [{"type": "event", "identifier": "", "variables": [{"name": ""}]}, {"type": "event", "identifier": "", "variables": [{"name": ""}, {"name": ""}, {"name": ""}]}]}, "preference": {"enabled": false, "channels": {}}} + "201": + application/json: {"key": ""} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_getNotificationsFeed: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_listTopics: "": parameters: - path: - subscriberId: "" query: - limit: 10 - payload: "btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=" + page: 0 + pageSize: 10 + key: "exampleKey" header: {} responses: "200": - application/json: {"totalCount": 5, "hasMore": true, "data": [{"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "push", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}, {"_id": "615c1f2f9b0c5b001f8e4e3b", "_templateId": "template_12345", "_environmentId": "env_67890", "_messageTemplateId": "message_template_54321", "_organizationId": "org_98765", "_notificationId": "notification_123456", "_subscriberId": "subscriber_112233", "_feedId": "feed_445566", "_jobId": "job_778899", "createdAt": "2024-12-10T10:10:59.639Z", "updatedAt": "2024-12-10T10:10:59.639Z", "actor": {"data": null, "type": "system_icon"}, "transactionId": "transaction_123456", "templateIdentifier": "template_abcdef", "providerId": "provider_xyz", "content": "This is a test notification content.", "subject": "Test Notification Subject", "channel": "in_app", "read": false, "seen": true, "deleted": false, "deviceTokens": ["token1", "token2"], "cta": {"data": {}}, "status": "sent", "payload": {"key": "value"}, "overrides": {"overrideKey": "overrideValue"}}], "pageSize": 2, "page": 1} + application/json: {"data": [], "page": 1, "pageSize": 10, "totalCount": 10} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Must be a valid email address"], "value": "invalidEmail"}, "fieldName2": {"messages": ["Must be at least 18 years old"], "value": 17}, "fieldName3": {"messages": ["Must be a boolean value"], "value": true}, "fieldName4": {"messages": ["Must be a valid object"], "value": {"key": "value"}}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Must be a valid email address"], "value": "invalidEmail"}, "fieldName2": {"messages": ["Must be at least 18 years old"], "value": 17}, "fieldName3": {"messages": ["Must be a boolean value"], "value": true}, "fieldName4": {"messages": ["Must be a valid object"], "value": [{"key": "value"}]}, "fieldName5": {"messages": ["Field is missing"], "value": null}, "fieldName6": {"messages": ["Undefined value"]}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_getUnseenCount: - speakeasy-default-subscribers-v1-controller-get-unseen-count: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_deleteTopic: + speakeasy-default-topics-controller-delete-topic: parameters: path: - subscriberId: "" - query: - seen: false - limit: 100 + topicKey: "" header: {} responses: - "200": - application/json: {"count": 2166.35} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_markMessagesAs: - speakeasy-default-subscribers-v1-controller-mark-messages-as: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_getTopic: + speakeasy-default-topics-controller-get-topic: parameters: path: - subscriberId: "" + topicKey: "" header: {} - requestBody: - application/json: {"messageId": "", "markAs": "unread"} responses: - "201": - application/json: [{"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"subscriberId": "", "channels": [{"providerId": "pusher-beams", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1724805777868", "updatedAt": "1738275840281"}, "createdAt": "1728104821657", "content": {"type": "button", "content": ""}, "transactionId": "", "channel": "email", "read": false, "seen": true, "cta": {"data": {}}, "status": "error"}] + "200": + application/json: {"_organizationId": "", "_environmentId": "", "key": "", "name": "", "subscribers": [""]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_markAllUnreadAsRead: - speakeasy-default-subscribers-v1-controller-mark-all-unread-as-read: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_renameTopic: + speakeasy-default-topics-controller-rename-topic: parameters: path: - subscriberId: "" + topicKey: "" header: {} requestBody: - application/json: {"markAs": "seen"} + application/json: {"name": ""} responses: - "201": - application/json: 4603.37 + "200": + application/json: {"_organizationId": "", "_environmentId": "", "key": "", "name": "", "subscribers": ["", "", ""]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_markActionAsSeen: - speakeasy-default-subscribers-v1-controller-mark-action-as-seen: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_assign: + speakeasy-default-topics-controller-assign: parameters: path: - messageId: "" - type: "" - subscriberId: "" + topicKey: "" header: {} requestBody: - application/json: {"status": "done"} - responses: - "201": - application/json: {"_templateId": "", "_environmentId": "", "_messageTemplateId": "", "_organizationId": "", "_notificationId": "", "_subscriberId": "", "subscriber": {"subscriberId": "", "channels": [{"providerId": "push-webhook", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}, {"providerId": "ryver", "credentials": {"webhookUrl": "https://example.com/webhook", "channel": "general", "deviceTokens": ["token1", "token2", "token3"], "alertUid": "12345-abcde", "title": "Critical Alert", "imageUrl": "https://example.com/image.png", "state": "resolved", "externalUrl": "https://example.com/details"}, "_integrationId": ""}], "_organizationId": "", "_environmentId": "", "deleted": true, "createdAt": "1737231087703", "updatedAt": "1738221054404"}, "createdAt": "1714813630400", "content": {"type": "text", "content": ""}, "transactionId": "", "channel": "sms", "read": true, "seen": true, "cta": {"data": {}}, "status": "sent"} - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_chatOauthCallback: - speakeasy-default-subscribers-v1-controller-chat-oauth-callback: - parameters: - path: - subscriberId: "" - providerId: "" - query: - hmacHash: "" - environmentId: "" - code: "" - header: {} + application/json: {"subscribers": ["", "", ""]} responses: "200": - text/html: "" - "302": - application/json: "" - "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} - "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersV1Controller_chatAccessOauth: - speakeasy-default-subscribers-v1-controller-chat-access-oauth: - parameters: - path: - subscriberId: "" - providerId: "" - query: - hmacHash: "" - environmentId: "" - header: {} - responses: + application/json: {"succeeded": []} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_getSubscriberPreferences: - speakeasy-default-subscribers-controller-get-subscriber-preferences: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_getTopicSubscriber: + speakeasy-default-topics-controller-get-topic-subscriber: parameters: path: - subscriberId: "" + externalSubscriberId: "" + topicKey: "" header: {} responses: "200": - application/json: {"global": {"enabled": true, "channels": {}}, "workflows": [{"enabled": true, "channels": {}, "overrides": [{"channel": "in_app", "source": "template"}], "workflow": {"slug": "", "identifier": "", "name": ""}}, {"enabled": false, "channels": {}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}, {"enabled": false, "channels": {}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}]} + application/json: {"_organizationId": "org_123456789", "_environmentId": "env_123456789", "_subscriberId": "sub_123456789", "_topicId": "topic_123456789", "topicKey": "my_topic_key", "externalSubscriberId": "external_subscriber_123"} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} - SubscribersController_updateSubscriberPreferences: - speakeasy-default-subscribers-controller-update-subscriber-preferences: + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + TopicsController_removeSubscribers: + speakeasy-default-topics-controller-remove-subscribers: parameters: path: - subscriberId: "" + topicKey: "" header: {} requestBody: - application/json: {"channels": {}} + application/json: {"subscribers": ["", ""]} responses: - "200": - application/json: {"global": {"enabled": false, "channels": {}}, "workflows": [{"enabled": true, "channels": {}, "overrides": [{"channel": "chat", "source": "template"}, {"channel": "push", "source": "subscriber"}, {"channel": "push", "source": "template"}], "workflow": {"slug": "", "identifier": "", "name": ""}}, {"enabled": true, "channels": {}, "overrides": [], "workflow": {"slug": "", "identifier": "", "name": ""}}]} "414": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "400": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} "422": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123", "errors": {"fieldName1": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName2": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName3": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName4": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName5": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}, "fieldName6": {"messages": ["Field is required", "Invalid format"], "value": "xx xx xx "}}} "500": - application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "Resource not found.", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} -examplesVersion: 1.0.0 + application/json: {"statusCode": 404, "timestamp": "2024-12-12T13:00:00Z", "path": "/api/v1/resource", "message": "xx xx xx ", "ctx": {"workflowId": "some_wf_id", "stepId": "some_wf_id"}, "errorId": "abc123"} +examplesVersion: 1.0.1 generatedTests: EventsController_trigger: "2024-12-24T08:36:06+01:00" EventsController_triggerBulk: "2024-12-24T08:36:06+01:00" diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 6dab927d..9a103c95 100755 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -11,11 +11,12 @@ generation: parameterOrderingFeb2024: true requestResponseComponentNamesFeb2024: true securityFeb2025: false + sharedErrorComponentsApr2025: false auth: oAuth2ClientCredentialsEnabled: false oAuth2PasswordEnabled: false typescript: - version: 0.6.2 + version: 0.7.0 additionalDependencies: dependencies: {} devDependencies: {} diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 5b4a6327..d1365924 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,21 +1,21 @@ -speakeasyVersion: 1.526.6 +speakeasyVersion: 1.542.3 sources: json-development: sourceNamespace: json-development - sourceRevisionDigest: sha256:d6dc088e8de8faa4118b35808a8dac1bf96011ce257bbc51e2bf00806aff43e1 - sourceBlobDigest: sha256:06a6410e2900a1591bed3235b238dfdf1c8baaabd8c2fb12cadc31dcc9e201aa + sourceRevisionDigest: sha256:2f71599ed61b2d4fbcba3e85c110214d27659ba10eba323cd188e26fe7e0963f + sourceBlobDigest: sha256:720d4154c543b24b8efe4b525edf028d2d5384ea027b5ac3daace2f207e578fc tags: - latest - - speakeasy-sdk-regen-1742516315 - - "1.0" + - speakeasy-sdk-regen-1743553146 + - 2.1.13 targets: my-first-target: source: json-development sourceNamespace: json-development - sourceRevisionDigest: sha256:d6dc088e8de8faa4118b35808a8dac1bf96011ce257bbc51e2bf00806aff43e1 - sourceBlobDigest: sha256:06a6410e2900a1591bed3235b238dfdf1c8baaabd8c2fb12cadc31dcc9e201aa + sourceRevisionDigest: sha256:2f71599ed61b2d4fbcba3e85c110214d27659ba10eba323cd188e26fe7e0963f + sourceBlobDigest: sha256:720d4154c543b24b8efe4b525edf028d2d5384ea027b5ac3daace2f207e578fc codeSamplesNamespace: code-samples-typescript - codeSamplesRevisionDigest: sha256:b7d470e68a420c97b470ded4606b072881feba4fd696a337f42a84c3e6f71034 + codeSamplesRevisionDigest: sha256:a2d0be257cdadef1f306fd26b548b97bc314c7d4f6782c34f6d07d7e535c5ff0 workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/FUNCTIONS.md b/FUNCTIONS.md index 665fffab..f0d940e7 100644 --- a/FUNCTIONS.md +++ b/FUNCTIONS.md @@ -39,9 +39,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, diff --git a/README.md b/README.md index 516df1de..0ecaa42b 100644 --- a/README.md +++ b/README.md @@ -204,9 +204,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -261,6 +270,29 @@ async function run() { "text": "string", }, }, + overrides: { + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }); // Handle the result @@ -292,9 +324,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -311,9 +352,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -333,9 +383,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -595,9 +654,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -695,9 +763,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -735,9 +812,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -833,9 +919,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -876,9 +971,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -934,9 +1038,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, diff --git a/RELEASES.md b/RELEASES.md index 5c24bf30..949fa96a 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -148,4 +148,14 @@ Based on: ### Generated - [typescript v0.6.2] . ### Releases -- [NPM v0.6.2] https://www.npmjs.com/package/@novu/api/v/0.6.2 - . \ No newline at end of file +- [NPM v0.6.2] https://www.npmjs.com/package/@novu/api/v/0.6.2 - . + +## 2025-05-08 00:19:36 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.542.3 (2.597.9) https://github.com/speakeasy-api/speakeasy +### Generated +- [typescript v0.7.0] . +### Releases +- [NPM v0.7.0] https://www.npmjs.com/package/@novu/api/v/0.7.0 - . \ No newline at end of file diff --git a/USAGE.md b/USAGE.md index 7dd4a209..6d4c5c84 100644 --- a/USAGE.md +++ b/USAGE.md @@ -18,9 +18,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -75,6 +84,29 @@ async function run() { "text": "string", }, }, + overrides: { + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }); // Handle the result @@ -106,9 +138,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -125,9 +166,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -147,9 +197,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, diff --git a/docs/models/components/activitiesresponsedto.md b/docs/models/components/activitiesresponsedto.md index a13ffc83..040db9ee 100644 --- a/docs/models/components/activitiesresponsedto.md +++ b/docs/models/components/activitiesresponsedto.md @@ -7,9 +7,59 @@ import { ActivitiesResponseDto } from "@novu/api/models/components"; let value: ActivitiesResponseDto = { hasMore: false, - data: [], - pageSize: 2074.7, - page: 4246.85, + data: [ + { + environmentId: "", + organizationId: "", + subscriberId: "", + transactionId: "", + jobs: [ + { + id: "", + type: "chat", + executionDetails: [ + { + id: "", + status: "ReadConfirmation", + detail: "", + isRetry: false, + isTest: false, + providerId: "africas-talking", + source: "Payload", + }, + ], + step: { + id: "", + active: false, + filters: [ + { + isNegated: false, + type: "TEXT", + value: "AND", + children: [ + { + field: "", + value: "", + operator: "SMALLER_EQUAL", + on: "payload", + }, + ], + }, + ], + templateId: "", + }, + overrides: { + "workflowId": "some_wf_id", + "stepId": "some_wf_id", + }, + providerId: "africas-talking", + status: "", + }, + ], + }, + ], + pageSize: 8294.52, + page: 7052.05, }; ``` diff --git a/docs/models/components/activitygraphstatesresponse.md b/docs/models/components/activitygraphstatesresponse.md index aef90595..72d8fec4 100644 --- a/docs/models/components/activitygraphstatesresponse.md +++ b/docs/models/components/activitygraphstatesresponse.md @@ -7,12 +7,12 @@ import { ActivityGraphStatesResponse } from "@novu/api/models/components"; let value: ActivityGraphStatesResponse = { id: "", - count: 5864.1, + count: 649.95, templates: [ "", ], channels: [ - "in_app", + "email", ], }; ``` diff --git a/docs/models/components/activitynotificationexecutiondetailresponsedto.md b/docs/models/components/activitynotificationexecutiondetailresponsedto.md index 5a85581a..b18ba01e 100644 --- a/docs/models/components/activitynotificationexecutiondetailresponsedto.md +++ b/docs/models/components/activitynotificationexecutiondetailresponsedto.md @@ -7,12 +7,12 @@ import { ActivityNotificationExecutionDetailResponseDto } from "@novu/api/models let value: ActivityNotificationExecutionDetailResponseDto = { id: "", - status: "ReadConfirmation", + status: "Pending", detail: "", isRetry: false, isTest: false, - providerId: "apns", - source: "Payload", + providerId: "emailjs", + source: "Credentials", }; ``` diff --git a/docs/models/components/activitynotificationjobresponsedto.md b/docs/models/components/activitynotificationjobresponsedto.md index 74287896..2b1242c9 100644 --- a/docs/models/components/activitynotificationjobresponsedto.md +++ b/docs/models/components/activitynotificationjobresponsedto.md @@ -7,16 +7,16 @@ import { ActivityNotificationJobResponseDto } from "@novu/api/models/components" let value: ActivityNotificationJobResponseDto = { id: "", - type: "push", + type: "in_app", executionDetails: [ { id: "", - status: "Warning", + status: "Success", detail: "", isRetry: false, isTest: false, - providerId: "sendchamp", - source: "Webhook", + providerId: "sparkpost", + source: "Credentials", }, ], step: { @@ -25,14 +25,14 @@ let value: ActivityNotificationJobResponseDto = { filters: [ { isNegated: false, - type: "BOOLEAN", - value: "OR", + type: "LIST", + value: "AND", children: [ { field: "", value: "", - operator: "SMALLER", - on: "payload", + operator: "NOT_IN", + on: "subscriber", }, ], }, @@ -43,7 +43,7 @@ let value: ActivityNotificationJobResponseDto = { "workflowId": "some_wf_id", "stepId": "some_wf_id", }, - providerId: "twilio", + providerId: "pusher-beams", status: "", }; ``` @@ -58,7 +58,7 @@ let value: ActivityNotificationJobResponseDto = { | `executionDetails` | [components.ActivityNotificationExecutionDetailResponseDto](../../models/components/activitynotificationexecutiondetailresponsedto.md)[] | :heavy_check_mark: | Execution details of the job | | | `step` | [components.ActivityNotificationStepResponseDto](../../models/components/activitynotificationstepresponsedto.md) | :heavy_check_mark: | Step details of the job | | | `overrides` | Record | :heavy_minus_sign: | Optional context object for additional error details. | {
"workflowId": "some_wf_id",
"stepId": "some_wf_id"
} | -| `payload` | [components.Payload](../../models/components/payload.md) | :heavy_minus_sign: | Optional payload for the job | | +| `payload` | [components.ActivityNotificationJobResponseDtoPayload](../../models/components/activitynotificationjobresponsedtopayload.md) | :heavy_minus_sign: | Optional payload for the job | | | `providerId` | [components.ProvidersIdEnum](../../models/components/providersidenum.md) | :heavy_check_mark: | Provider ID of the job | | | `status` | *string* | :heavy_check_mark: | Status of the job | | | `updatedAt` | *string* | :heavy_minus_sign: | Updated time of the notification | | \ No newline at end of file diff --git a/docs/models/components/activitynotificationjobresponsedtopayload.md b/docs/models/components/activitynotificationjobresponsedtopayload.md new file mode 100644 index 00000000..08023d1e --- /dev/null +++ b/docs/models/components/activitynotificationjobresponsedtopayload.md @@ -0,0 +1,16 @@ +# ActivityNotificationJobResponseDtoPayload + +Optional payload for the job + +## Example Usage + +```typescript +import { ActivityNotificationJobResponseDtoPayload } from "@novu/api/models/components"; + +let value: ActivityNotificationJobResponseDtoPayload = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/components/activitynotificationjobresponsedtotype.md b/docs/models/components/activitynotificationjobresponsedtotype.md index d482b48d..b78f1e17 100644 --- a/docs/models/components/activitynotificationjobresponsedtotype.md +++ b/docs/models/components/activitynotificationjobresponsedtotype.md @@ -7,7 +7,7 @@ Type of the job ```typescript import { ActivityNotificationJobResponseDtoType } from "@novu/api/models/components"; -let value: ActivityNotificationJobResponseDtoType = "chat"; +let value: ActivityNotificationJobResponseDtoType = "in_app"; ``` ## Values diff --git a/docs/models/components/activitynotificationresponsedto.md b/docs/models/components/activitynotificationresponsedto.md index c51daf74..14877e38 100644 --- a/docs/models/components/activitynotificationresponsedto.md +++ b/docs/models/components/activitynotificationresponsedto.md @@ -10,7 +10,49 @@ let value: ActivityNotificationResponseDto = { organizationId: "", subscriberId: "", transactionId: "", - jobs: [], + jobs: [ + { + id: "", + type: "sms", + executionDetails: [ + { + id: "", + status: "Queued", + detail: "", + isRetry: false, + isTest: false, + providerId: "mailersend", + source: "Payload", + }, + ], + step: { + id: "", + active: false, + filters: [ + { + isNegated: false, + type: "BOOLEAN", + value: "OR", + children: [ + { + field: "", + value: "", + operator: "NOT_LIKE", + on: "subscriber", + }, + ], + }, + ], + templateId: "", + }, + overrides: { + "workflowId": "some_wf_id", + "stepId": "some_wf_id", + }, + providerId: "pushpad", + status: "", + }, + ], }; ``` diff --git a/docs/models/components/activitynotificationstepresponsedto.md b/docs/models/components/activitynotificationstepresponsedto.md index dda161d9..2bb267da 100644 --- a/docs/models/components/activitynotificationstepresponsedto.md +++ b/docs/models/components/activitynotificationstepresponsedto.md @@ -11,13 +11,13 @@ let value: ActivityNotificationStepResponseDto = { filters: [ { isNegated: false, - type: "TEXT", - value: "AND", + type: "BOOLEAN", + value: "OR", children: [ { field: "", value: "", - operator: "ALL_IN", + operator: "EQUAL", on: "subscriber", }, ], @@ -35,7 +35,7 @@ let value: ActivityNotificationStepResponseDto = { | `active` | *boolean* | :heavy_check_mark: | Whether the step is active or not | | `replyCallback` | [components.ActivityNotificationStepResponseDtoReplyCallback](../../models/components/activitynotificationstepresponsedtoreplycallback.md) | :heavy_minus_sign: | Reply callback settings | | `controlVariables` | [components.ControlVariables](../../models/components/controlvariables.md) | :heavy_minus_sign: | Control variables | -| `metadata` | [components.Metadata](../../models/components/metadata.md) | :heavy_minus_sign: | Metadata for the workflow step | +| `metadata` | [components.ActivityNotificationStepResponseDtoMetadata](../../models/components/activitynotificationstepresponsedtometadata.md) | :heavy_minus_sign: | Metadata for the workflow step | | `issues` | [components.Issues](../../models/components/issues.md) | :heavy_minus_sign: | Step issues | | `filters` | [components.StepFilterDto](../../models/components/stepfilterdto.md)[] | :heavy_check_mark: | Filter criteria for the step | | `template` | [components.MessageTemplateDto](../../models/components/messagetemplatedto.md) | :heavy_minus_sign: | Optional template for the step | diff --git a/docs/models/components/activitynotificationstepresponsedtometadata.md b/docs/models/components/activitynotificationstepresponsedtometadata.md new file mode 100644 index 00000000..d93cb0e8 --- /dev/null +++ b/docs/models/components/activitynotificationstepresponsedtometadata.md @@ -0,0 +1,16 @@ +# ActivityNotificationStepResponseDtoMetadata + +Metadata for the workflow step + +## Example Usage + +```typescript +import { ActivityNotificationStepResponseDtoMetadata } from "@novu/api/models/components"; + +let value: ActivityNotificationStepResponseDtoMetadata = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/components/activitystatsresponsedto.md b/docs/models/components/activitystatsresponsedto.md index 12773f80..264ed027 100644 --- a/docs/models/components/activitystatsresponsedto.md +++ b/docs/models/components/activitystatsresponsedto.md @@ -6,8 +6,8 @@ import { ActivityStatsResponseDto } from "@novu/api/models/components"; let value: ActivityStatsResponseDto = { - weeklySent: 4856.28, - monthlySent: 9774.96, + weeklySent: 1720.51, + monthlySent: 2987.66, }; ``` diff --git a/docs/models/components/actorfeeditemdto.md b/docs/models/components/actorfeeditemdto.md index 35e7362d..ddc1d3dd 100644 --- a/docs/models/components/actorfeeditemdto.md +++ b/docs/models/components/actorfeeditemdto.md @@ -7,7 +7,7 @@ import { ActorFeedItemDto } from "@novu/api/models/components"; let value: ActorFeedItemDto = { data: null, - type: "none", + type: "user", }; ``` diff --git a/docs/models/components/actortypeenum.md b/docs/models/components/actortypeenum.md index b391da0d..0e85f173 100644 --- a/docs/models/components/actortypeenum.md +++ b/docs/models/components/actortypeenum.md @@ -7,7 +7,7 @@ The type of the actor, indicating the role in the notification process. ```typescript import { ActorTypeEnum } from "@novu/api/models/components"; -let value: ActorTypeEnum = "system_custom"; +let value: ActorTypeEnum = "none"; ``` ## Values diff --git a/docs/models/components/backoffunit.md b/docs/models/components/backoffunit.md index 5f168f5e..a7ea32ff 100644 --- a/docs/models/components/backoffunit.md +++ b/docs/models/components/backoffunit.md @@ -5,7 +5,7 @@ ```typescript import { BackoffUnit } from "@novu/api/models/components"; -let value: BackoffUnit = "seconds"; +let value: BackoffUnit = "weeks"; ``` ## Values diff --git a/docs/models/components/builderfieldtypeenum.md b/docs/models/components/builderfieldtypeenum.md index e19fb69e..8661de5b 100644 --- a/docs/models/components/builderfieldtypeenum.md +++ b/docs/models/components/builderfieldtypeenum.md @@ -5,7 +5,7 @@ ```typescript import { BuilderFieldTypeEnum } from "@novu/api/models/components"; -let value: BuilderFieldTypeEnum = "MULTI_LIST"; +let value: BuilderFieldTypeEnum = "BOOLEAN"; ``` ## Values diff --git a/docs/models/components/bulktriggereventdto.md b/docs/models/components/bulktriggereventdto.md index c95c7d40..cc5c5548 100644 --- a/docs/models/components/bulktriggereventdto.md +++ b/docs/models/components/bulktriggereventdto.md @@ -15,16 +15,10 @@ let value: BulkTriggerEventDto = { "text": "string", }, }, - overrides: { - "fcm": { - "data": { - "key": "value", - }, - }, + overrides: {}, + to: { + subscriberId: "", }, - to: [ - "SUBSCRIBER_ID", - ], }, ], }; diff --git a/docs/models/components/channel.md b/docs/models/components/channel.md index b1096853..0f457c8b 100644 --- a/docs/models/components/channel.md +++ b/docs/models/components/channel.md @@ -1,6 +1,6 @@ # Channel -The channel type which is overridden +The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). ## Example Usage diff --git a/docs/models/components/channels.md b/docs/models/components/channels.md index 6ae7eaf9..f6e5b156 100644 --- a/docs/models/components/channels.md +++ b/docs/models/components/channels.md @@ -5,7 +5,7 @@ ```typescript import { Channels } from "@novu/api/models/components"; -let value: Channels = "email"; +let value: Channels = "sms"; ``` ## Values diff --git a/docs/models/components/channelsettingsdto.md b/docs/models/components/channelsettingsdto.md index d28adc43..6119bb38 100644 --- a/docs/models/components/channelsettingsdto.md +++ b/docs/models/components/channelsettingsdto.md @@ -6,7 +6,7 @@ import { ChannelSettingsDto } from "@novu/api/models/components"; let value: ChannelSettingsDto = { - providerId: "mattermost", + providerId: "getstream", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -27,9 +27,9 @@ let value: ChannelSettingsDto = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | -| `providerId` | [components.ProviderId](../../models/components/providerid.md) | :heavy_check_mark: | The provider identifier for the credentials | -| `integrationIdentifier` | *string* | :heavy_minus_sign: | The integration identifier | -| `credentials` | [components.ChannelCredentials](../../models/components/channelcredentials.md) | :heavy_check_mark: | Credentials payload for the specified provider | -| `integrationId` | *string* | :heavy_check_mark: | The unique identifier of the integration associated with this channel. | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `providerId` | [components.ChatOrPushProviderEnum](../../models/components/chatorpushproviderenum.md) | :heavy_check_mark: | The provider identifier for the credentials | +| `integrationIdentifier` | *string* | :heavy_minus_sign: | The integration identifier | +| `credentials` | [components.ChannelCredentials](../../models/components/channelcredentials.md) | :heavy_check_mark: | Credentials payload for the specified provider | +| `integrationId` | *string* | :heavy_check_mark: | The unique identifier of the integration associated with this channel. | \ No newline at end of file diff --git a/docs/models/components/channeltypeenum.md b/docs/models/components/channeltypeenum.md index 04d28d7f..94f80e8b 100644 --- a/docs/models/components/channeltypeenum.md +++ b/docs/models/components/channeltypeenum.md @@ -7,7 +7,7 @@ Channel type through which the message is sent ```typescript import { ChannelTypeEnum } from "@novu/api/models/components"; -let value: ChannelTypeEnum = "in_app"; +let value: ChannelTypeEnum = "push"; ``` ## Values diff --git a/docs/models/components/updatesubscriberchannelrequestdtoproviderid.md b/docs/models/components/chatorpushproviderenum.md similarity index 61% rename from docs/models/components/updatesubscriberchannelrequestdtoproviderid.md rename to docs/models/components/chatorpushproviderenum.md index a5c1b48f..dc43c17d 100644 --- a/docs/models/components/updatesubscriberchannelrequestdtoproviderid.md +++ b/docs/models/components/chatorpushproviderenum.md @@ -1,13 +1,13 @@ -# UpdateSubscriberChannelRequestDtoProviderId +# ChatOrPushProviderEnum The provider identifier for the credentials ## Example Usage ```typescript -import { UpdateSubscriberChannelRequestDtoProviderId } from "@novu/api/models/components"; +import { ChatOrPushProviderEnum } from "@novu/api/models/components"; -let value: UpdateSubscriberChannelRequestDtoProviderId = "whatsapp-business"; +let value: ChatOrPushProviderEnum = "whatsapp-business"; ``` ## Values diff --git a/docs/models/components/constraintvalidation.md b/docs/models/components/constraintvalidation.md new file mode 100644 index 00000000..57f40370 --- /dev/null +++ b/docs/models/components/constraintvalidation.md @@ -0,0 +1,22 @@ +# ConstraintValidation + +## Example Usage + +```typescript +import { ConstraintValidation } from "@novu/api/models/components"; + +let value: ConstraintValidation = { + messages: [ + "Field is required", + "Invalid format", + ], + value: "xx xx xx ", +}; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | +| `messages` | *string*[] | :heavy_check_mark: | List of validation error messages | [
"Field is required",
"Invalid format"
] | +| `value` | *components.Value* | :heavy_minus_sign: | Value that failed validation | xx xx xx | \ No newline at end of file diff --git a/docs/models/components/content.md b/docs/models/components/content.md index 17223e98..18ae68d4 100644 --- a/docs/models/components/content.md +++ b/docs/models/components/content.md @@ -5,13 +5,15 @@ Content of the message, can be an email block or a string ## Supported Types -### `components.EmailBlock` +### `components.EmailBlock[]` ```typescript -const value: components.EmailBlock = { - type: "text", - content: "", -}; +const value: components.EmailBlock[] = [ + { + type: "text", + content: "", + }, +]; ``` ### `string` diff --git a/docs/models/components/createintegrationrequestdto.md b/docs/models/components/createintegrationrequestdto.md index cc2bba08..5ff93fdc 100644 --- a/docs/models/components/createintegrationrequestdto.md +++ b/docs/models/components/createintegrationrequestdto.md @@ -7,7 +7,7 @@ import { CreateIntegrationRequestDto } from "@novu/api/models/components"; let value: CreateIntegrationRequestDto = { providerId: "", - channel: "in_app", + channel: "sms", }; ``` diff --git a/docs/models/components/createintegrationrequestdtochannel.md b/docs/models/components/createintegrationrequestdtochannel.md index 6feb4600..939fa732 100644 --- a/docs/models/components/createintegrationrequestdtochannel.md +++ b/docs/models/components/createintegrationrequestdtochannel.md @@ -7,7 +7,7 @@ The channel type for the integration ```typescript import { CreateIntegrationRequestDtoChannel } from "@novu/api/models/components"; -let value: CreateIntegrationRequestDtoChannel = "sms"; +let value: CreateIntegrationRequestDtoChannel = "in_app"; ``` ## Values diff --git a/docs/models/components/delayregularmetadataunit.md b/docs/models/components/delayregularmetadataunit.md index a07e6c93..579f0e83 100644 --- a/docs/models/components/delayregularmetadataunit.md +++ b/docs/models/components/delayregularmetadataunit.md @@ -5,7 +5,7 @@ ```typescript import { DelayRegularMetadataUnit } from "@novu/api/models/components"; -let value: DelayRegularMetadataUnit = "seconds"; +let value: DelayRegularMetadataUnit = "hours"; ``` ## Values diff --git a/docs/models/components/digestmetadatadto.md b/docs/models/components/digestmetadatadto.md index 93a9afe6..73f248dd 100644 --- a/docs/models/components/digestmetadatadto.md +++ b/docs/models/components/digestmetadatadto.md @@ -6,21 +6,21 @@ import { DigestMetadataDto } from "@novu/api/models/components"; let value: DigestMetadataDto = { - type: "backoff", + type: "timed", }; ``` ## Fields -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------- | -| `digestKey` | *string* | :heavy_minus_sign: | Optional key for the digest | -| `amount` | *number* | :heavy_minus_sign: | Amount for the digest | -| `unit` | [components.Unit](../../models/components/unit.md) | :heavy_minus_sign: | Unit of the digest | -| `type` | [components.DigestTypeEnum](../../models/components/digesttypeenum.md) | :heavy_check_mark: | The Digest Type | -| `events` | Record[] | :heavy_minus_sign: | Optional array of events associated with the digest, represented as key-value pairs | -| `backoff` | *boolean* | :heavy_minus_sign: | Regular digest: Indicates if backoff is enabled for the regular digest | -| `backoffAmount` | *number* | :heavy_minus_sign: | Regular digest: Amount for backoff | -| `backoffUnit` | [components.DigestUnitEnum](../../models/components/digestunitenum.md) | :heavy_minus_sign: | Regular digest: Unit for backoff | -| `updateMode` | *boolean* | :heavy_minus_sign: | Regular digest: Indicates if the digest should update | -| `timed` | [components.DigestTimedConfigDto](../../models/components/digesttimedconfigdto.md) | :heavy_minus_sign: | Configuration for timed digest | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `digestKey` | *string* | :heavy_minus_sign: | Optional key for the digest | +| `amount` | *number* | :heavy_minus_sign: | Amount for the digest | +| `unit` | [components.DigestMetadataDtoUnit](../../models/components/digestmetadatadtounit.md) | :heavy_minus_sign: | Unit of the digest | +| `type` | [components.DigestTypeEnum](../../models/components/digesttypeenum.md) | :heavy_check_mark: | The Digest Type | +| `events` | Record[] | :heavy_minus_sign: | Optional array of events associated with the digest, represented as key-value pairs | +| `backoff` | *boolean* | :heavy_minus_sign: | Regular digest: Indicates if backoff is enabled for the regular digest | +| `backoffAmount` | *number* | :heavy_minus_sign: | Regular digest: Amount for backoff | +| `backoffUnit` | [components.DigestUnitEnum](../../models/components/digestunitenum.md) | :heavy_minus_sign: | Regular digest: Unit for backoff | +| `updateMode` | *boolean* | :heavy_minus_sign: | Regular digest: Indicates if the digest should update | +| `timed` | [components.DigestTimedConfigDto](../../models/components/digesttimedconfigdto.md) | :heavy_minus_sign: | Configuration for timed digest | \ No newline at end of file diff --git a/docs/models/components/digestmetadatadtounit.md b/docs/models/components/digestmetadatadtounit.md new file mode 100644 index 00000000..d6cb4cbe --- /dev/null +++ b/docs/models/components/digestmetadatadtounit.md @@ -0,0 +1,17 @@ +# DigestMetadataDtoUnit + +Unit of the digest + +## Example Usage + +```typescript +import { DigestMetadataDtoUnit } from "@novu/api/models/components"; + +let value: DigestMetadataDtoUnit = "hours"; +``` + +## Values + +```typescript +"seconds" | "minutes" | "hours" | "days" | "weeks" | "months" +``` \ No newline at end of file diff --git a/docs/models/components/digestregularmetadata.md b/docs/models/components/digestregularmetadata.md index 3a7ec949..97aa2c55 100644 --- a/docs/models/components/digestregularmetadata.md +++ b/docs/models/components/digestregularmetadata.md @@ -6,19 +6,19 @@ import { DigestRegularMetadata } from "@novu/api/models/components"; let value: DigestRegularMetadata = { - type: "regular", + type: "backoff", }; ``` ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -| `amount` | *number* | :heavy_minus_sign: | N/A | -| `unit` | [components.DigestRegularMetadataUnit](../../models/components/digestregularmetadataunit.md) | :heavy_minus_sign: | N/A | -| `digestKey` | *string* | :heavy_minus_sign: | N/A | -| `type` | [components.DigestRegularMetadataType](../../models/components/digestregularmetadatatype.md) | :heavy_check_mark: | N/A | -| `backoff` | *boolean* | :heavy_minus_sign: | N/A | -| `backoffAmount` | *number* | :heavy_minus_sign: | N/A | -| `backoffUnit` | [components.BackoffUnit](../../models/components/backoffunit.md) | :heavy_minus_sign: | N/A | -| `updateMode` | *boolean* | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `amount` | *number* | :heavy_minus_sign: | N/A | +| `unit` | [components.Unit](../../models/components/unit.md) | :heavy_minus_sign: | N/A | +| `digestKey` | *string* | :heavy_minus_sign: | N/A | +| `type` | [components.Type](../../models/components/type.md) | :heavy_check_mark: | N/A | +| `backoff` | *boolean* | :heavy_minus_sign: | N/A | +| `backoffAmount` | *number* | :heavy_minus_sign: | N/A | +| `backoffUnit` | [components.BackoffUnit](../../models/components/backoffunit.md) | :heavy_minus_sign: | N/A | +| `updateMode` | *boolean* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/digestregularmetadatatype.md b/docs/models/components/digestregularmetadatatype.md deleted file mode 100644 index 5ec02ff1..00000000 --- a/docs/models/components/digestregularmetadatatype.md +++ /dev/null @@ -1,15 +0,0 @@ -# DigestRegularMetadataType - -## Example Usage - -```typescript -import { DigestRegularMetadataType } from "@novu/api/models/components"; - -let value: DigestRegularMetadataType = "regular"; -``` - -## Values - -```typescript -"regular" | "backoff" -``` \ No newline at end of file diff --git a/docs/models/components/digestregularmetadataunit.md b/docs/models/components/digestregularmetadataunit.md deleted file mode 100644 index 48903e27..00000000 --- a/docs/models/components/digestregularmetadataunit.md +++ /dev/null @@ -1,15 +0,0 @@ -# DigestRegularMetadataUnit - -## Example Usage - -```typescript -import { DigestRegularMetadataUnit } from "@novu/api/models/components"; - -let value: DigestRegularMetadataUnit = "minutes"; -``` - -## Values - -```typescript -"seconds" | "minutes" | "hours" | "days" | "weeks" | "months" -``` \ No newline at end of file diff --git a/docs/models/components/digesttimedconfigdto.md b/docs/models/components/digesttimedconfigdto.md index b548f646..e5db28fa 100644 --- a/docs/models/components/digesttimedconfigdto.md +++ b/docs/models/components/digesttimedconfigdto.md @@ -10,12 +10,12 @@ let value: DigestTimedConfigDto = {}; ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -------------------------------------------------------------------------- | -| `atTime` | *string* | :heavy_minus_sign: | Time at which the digest is triggered | -| `weekDays` | [components.WeekDays](../../models/components/weekdays.md)[] | :heavy_minus_sign: | Days of the week for the digest | -| `monthDays` | *number*[] | :heavy_minus_sign: | Specific days of the month for the digest | -| `ordinal` | [components.OrdinalEnum](../../models/components/ordinalenum.md) | :heavy_minus_sign: | Ordinal position for the digest | -| `ordinalValue` | [components.OrdinalValueEnum](../../models/components/ordinalvalueenum.md) | :heavy_minus_sign: | Value of the ordinal | -| `monthlyType` | [components.MonthlyTypeEnum](../../models/components/monthlytypeenum.md) | :heavy_minus_sign: | Type of monthly schedule | -| `cronExpression` | *string* | :heavy_minus_sign: | Cron expression for scheduling | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------- | +| `atTime` | *string* | :heavy_minus_sign: | Time at which the digest is triggered | +| `weekDays` | [components.DigestTimedConfigDtoWeekDays](../../models/components/digesttimedconfigdtoweekdays.md)[] | :heavy_minus_sign: | Days of the week for the digest | +| `monthDays` | *number*[] | :heavy_minus_sign: | Specific days of the month for the digest | +| `ordinal` | [components.OrdinalEnum](../../models/components/ordinalenum.md) | :heavy_minus_sign: | Ordinal position for the digest | +| `ordinalValue` | [components.OrdinalValueEnum](../../models/components/ordinalvalueenum.md) | :heavy_minus_sign: | Value of the ordinal | +| `monthlyType` | [components.MonthlyTypeEnum](../../models/components/monthlytypeenum.md) | :heavy_minus_sign: | Type of monthly schedule | +| `cronExpression` | *string* | :heavy_minus_sign: | Cron expression for scheduling | \ No newline at end of file diff --git a/docs/models/components/digesttimedconfigdtoweekdays.md b/docs/models/components/digesttimedconfigdtoweekdays.md new file mode 100644 index 00000000..f5af7adf --- /dev/null +++ b/docs/models/components/digesttimedconfigdtoweekdays.md @@ -0,0 +1,15 @@ +# DigestTimedConfigDtoWeekDays + +## Example Usage + +```typescript +import { DigestTimedConfigDtoWeekDays } from "@novu/api/models/components"; + +let value: DigestTimedConfigDtoWeekDays = "sunday"; +``` + +## Values + +```typescript +"monday" | "tuesday" | "wednesday" | "thursday" | "friday" | "saturday" | "sunday" +``` \ No newline at end of file diff --git a/docs/models/components/digesttimedmetadataunit.md b/docs/models/components/digesttimedmetadataunit.md index 723eeed7..0930da26 100644 --- a/docs/models/components/digesttimedmetadataunit.md +++ b/docs/models/components/digesttimedmetadataunit.md @@ -5,7 +5,7 @@ ```typescript import { DigestTimedMetadataUnit } from "@novu/api/models/components"; -let value: DigestTimedMetadataUnit = "minutes"; +let value: DigestTimedMetadataUnit = "days"; ``` ## Values diff --git a/docs/models/components/digesttypeenum.md b/docs/models/components/digesttypeenum.md index a42421fd..e241c343 100644 --- a/docs/models/components/digesttypeenum.md +++ b/docs/models/components/digesttypeenum.md @@ -7,7 +7,7 @@ The Digest Type ```typescript import { DigestTypeEnum } from "@novu/api/models/components"; -let value: DigestTypeEnum = "timed"; +let value: DigestTypeEnum = "backoff"; ``` ## Values diff --git a/docs/models/components/digestunitenum.md b/docs/models/components/digestunitenum.md index cbb62243..9179c371 100644 --- a/docs/models/components/digestunitenum.md +++ b/docs/models/components/digestunitenum.md @@ -7,7 +7,7 @@ Regular digest: Unit for backoff ```typescript import { DigestUnitEnum } from "@novu/api/models/components"; -let value: DigestUnitEnum = "seconds"; +let value: DigestUnitEnum = "days"; ``` ## Values diff --git a/docs/models/components/emailblock.md b/docs/models/components/emailblock.md index 28eaff93..f65cb431 100644 --- a/docs/models/components/emailblock.md +++ b/docs/models/components/emailblock.md @@ -6,7 +6,7 @@ import { EmailBlock } from "@novu/api/models/components"; let value: EmailBlock = { - type: "button", + type: "text", content: "", }; ``` diff --git a/docs/models/components/executiondetailsstatusenum.md b/docs/models/components/executiondetailsstatusenum.md index 7ff03dee..5758ec52 100644 --- a/docs/models/components/executiondetailsstatusenum.md +++ b/docs/models/components/executiondetailsstatusenum.md @@ -7,7 +7,7 @@ Status of the execution detail ```typescript import { ExecutionDetailsStatusEnum } from "@novu/api/models/components"; -let value: ExecutionDetailsStatusEnum = "Success"; +let value: ExecutionDetailsStatusEnum = "Pending"; ``` ## Values diff --git a/docs/models/components/feedresponsedto.md b/docs/models/components/feedresponsedto.md index 394ccda8..4ca2cb92 100644 --- a/docs/models/components/feedresponsedto.md +++ b/docs/models/components/feedresponsedto.md @@ -23,24 +23,21 @@ let value: FeedResponseDto = { updatedAt: new Date("2024-12-10T10:10:59.639Z"), actor: { data: null, - type: "system_custom", + type: "user", }, transactionId: "transaction_123456", templateIdentifier: "template_abcdef", providerId: "provider_xyz", content: "This is a test notification content.", subject: "Test Notification Subject", - channel: "in_app", + channel: "push", read: false, seen: true, - deleted: false, deviceTokens: [ "token1", "token2", ], - cta: { - data: {}, - }, + cta: {}, status: "sent", payload: { "key": "value", diff --git a/docs/models/components/fieldfilterpartdto.md b/docs/models/components/fieldfilterpartdto.md index 16c65323..0d2c589b 100644 --- a/docs/models/components/fieldfilterpartdto.md +++ b/docs/models/components/fieldfilterpartdto.md @@ -8,7 +8,7 @@ import { FieldFilterPartDto } from "@novu/api/models/components"; let value: FieldFilterPartDto = { field: "", value: "", - operator: "SMALLER_EQUAL", + operator: "NOT_IN", on: "subscriber", }; ``` diff --git a/docs/models/errors/value.md b/docs/models/components/five.md similarity index 64% rename from docs/models/errors/value.md rename to docs/models/components/five.md index 9a190805..ba4c9d4b 100644 --- a/docs/models/errors/value.md +++ b/docs/models/components/five.md @@ -1,4 +1,4 @@ -# Value +# Five ## Supported Types @@ -12,7 +12,7 @@ const value: string = ""; ### `number` ```typescript -const value: number = 8765.06; +const value: number = 1284.03; ``` ### `boolean` @@ -29,13 +29,3 @@ const value: { [k: string]: any } = { }; ``` -### `{ [k: string]: any }[]` - -```typescript -const value: { [k: string]: any }[] = [ - { - "key": "", - }, -]; -``` - diff --git a/docs/models/components/four.md b/docs/models/components/four.md new file mode 100644 index 00000000..66760117 --- /dev/null +++ b/docs/models/components/four.md @@ -0,0 +1,14 @@ +# Four + +## Example Usage + +```typescript +import { Four } from "@novu/api/models/components"; + +let value: Four = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/components/getsubscriberpreferencesdto.md b/docs/models/components/getsubscriberpreferencesdto.md index 670d0986..1ff08fe9 100644 --- a/docs/models/components/getsubscriberpreferencesdto.md +++ b/docs/models/components/getsubscriberpreferencesdto.md @@ -8,15 +8,27 @@ import { GetSubscriberPreferencesDto } from "@novu/api/models/components"; let value: GetSubscriberPreferencesDto = { global: { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, }, workflows: [ { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, overrides: [ { - channel: "push", + channel: "in_app", source: "template", }, ], @@ -32,7 +44,7 @@ let value: GetSubscriberPreferencesDto = { ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -| `global` | [components.GlobalPreferenceDto](../../models/components/globalpreferencedto.md) | :heavy_check_mark: | Global preference settings | -| `workflows` | [components.WorkflowPreferenceDto](../../models/components/workflowpreferencedto.md)[] | :heavy_check_mark: | Workflow-specific preference settings | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------- | +| `global` | [components.SubscriberGlobalPreferenceDto](../../models/components/subscriberglobalpreferencedto.md) | :heavy_check_mark: | Global preference settings | +| `workflows` | [components.SubscriberWorkflowPreferenceDto](../../models/components/subscriberworkflowpreferencedto.md)[] | :heavy_check_mark: | Workflow-specific preference settings | \ No newline at end of file diff --git a/docs/models/components/globalpreferencedto.md b/docs/models/components/globalpreferencedto.md deleted file mode 100644 index ed374ed7..00000000 --- a/docs/models/components/globalpreferencedto.md +++ /dev/null @@ -1,19 +0,0 @@ -# GlobalPreferenceDto - -## Example Usage - -```typescript -import { GlobalPreferenceDto } from "@novu/api/models/components"; - -let value: GlobalPreferenceDto = { - enabled: false, - channels: {}, -}; -``` - -## Fields - -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | -| `enabled` | *boolean* | :heavy_check_mark: | Whether notifications are enabled globally | -| `channels` | [components.PreferenceChannels](../../models/components/preferencechannels.md) | :heavy_check_mark: | Channel-specific preference settings | \ No newline at end of file diff --git a/docs/models/components/integrationresponsedto.md b/docs/models/components/integrationresponsedto.md index 2a012702..a995b6f5 100644 --- a/docs/models/components/integrationresponsedto.md +++ b/docs/models/components/integrationresponsedto.md @@ -11,7 +11,7 @@ let value: IntegrationResponseDto = { name: "", identifier: "", providerId: "", - channel: "email", + channel: "sms", credentials: {}, active: false, deleted: false, @@ -29,7 +29,7 @@ let value: IntegrationResponseDto = { | `name` | *string* | :heavy_check_mark: | The name of the integration, which is used to identify it in the user interface. | | `identifier` | *string* | :heavy_check_mark: | A unique string identifier for the integration, often used for API calls or internal references. | | `providerId` | *string* | :heavy_check_mark: | The identifier for the provider of the integration (e.g., "mailgun", "twilio"). | -| `channel` | [components.IntegrationResponseDtoChannel](../../models/components/integrationresponsedtochannel.md) | :heavy_check_mark: | The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). | +| `channel` | [components.Channel](../../models/components/channel.md) | :heavy_check_mark: | The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). | | `credentials` | [components.CredentialsDto](../../models/components/credentialsdto.md) | :heavy_check_mark: | The credentials required for the integration to function, including API keys and other sensitive information. | | `active` | *boolean* | :heavy_check_mark: | Indicates whether the integration is currently active. An active integration will process events and messages. | | `deleted` | *boolean* | :heavy_check_mark: | Indicates whether the integration has been marked as deleted (soft delete). | diff --git a/docs/models/components/integrationresponsedtochannel.md b/docs/models/components/integrationresponsedtochannel.md deleted file mode 100644 index 325b222a..00000000 --- a/docs/models/components/integrationresponsedtochannel.md +++ /dev/null @@ -1,17 +0,0 @@ -# IntegrationResponseDtoChannel - -The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). - -## Example Usage - -```typescript -import { IntegrationResponseDtoChannel } from "@novu/api/models/components"; - -let value: IntegrationResponseDtoChannel = "email"; -``` - -## Values - -```typescript -"in_app" | "email" | "sms" | "chat" | "push" -``` \ No newline at end of file diff --git a/docs/models/components/listsubscribersresponsedto.md b/docs/models/components/listsubscribersresponsedto.md index be1a6037..cf5249f7 100644 --- a/docs/models/components/listsubscribersresponsedto.md +++ b/docs/models/components/listsubscribersresponsedto.md @@ -8,10 +8,9 @@ import { ListSubscribersResponseDto } from "@novu/api/models/components"; let value: ListSubscribersResponseDto = { data: [ { - subscriberId: "", channels: [ { - providerId: "ryver", + providerId: "whatsapp-business", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -29,11 +28,12 @@ let value: ListSubscribersResponseDto = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1735088444289", - updatedAt: "1743436098471", + createdAt: "1739435486812", + updatedAt: "1746599677975", }, ], next: "", diff --git a/docs/models/components/markmessageactionasseendto.md b/docs/models/components/markmessageactionasseendto.md index 862a243c..9bb6816f 100644 --- a/docs/models/components/markmessageactionasseendto.md +++ b/docs/models/components/markmessageactionasseendto.md @@ -6,7 +6,7 @@ import { MarkMessageActionAsSeenDto } from "@novu/api/models/components"; let value: MarkMessageActionAsSeenDto = { - status: "pending", + status: "done", }; ``` diff --git a/docs/models/components/messageactionresult.md b/docs/models/components/messageactionresult.md index 0d4cabf0..8127f014 100644 --- a/docs/models/components/messageactionresult.md +++ b/docs/models/components/messageactionresult.md @@ -10,7 +10,7 @@ let value: MessageActionResult = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | -| `payload` | [components.MessageActionResultPayload](../../models/components/messageactionresultpayload.md) | :heavy_minus_sign: | Payload of the action result | -| `type` | [components.ButtonTypeEnum](../../models/components/buttontypeenum.md) | :heavy_minus_sign: | Type of button for the action result | \ No newline at end of file +| Field | Type | Required | Description | +| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | +| `payload` | [components.Payload](../../models/components/payload.md) | :heavy_minus_sign: | Payload of the action result | +| `type` | [components.ButtonTypeEnum](../../models/components/buttontypeenum.md) | :heavy_minus_sign: | Type of button for the action result | \ No newline at end of file diff --git a/docs/models/components/messageactionresultpayload.md b/docs/models/components/messageactionresultpayload.md deleted file mode 100644 index 19ab0136..00000000 --- a/docs/models/components/messageactionresultpayload.md +++ /dev/null @@ -1,16 +0,0 @@ -# MessageActionResultPayload - -Payload of the action result - -## Example Usage - -```typescript -import { MessageActionResultPayload } from "@novu/api/models/components"; - -let value: MessageActionResultPayload = {}; -``` - -## Fields - -| Field | Type | Required | Description | -| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/components/messagebutton.md b/docs/models/components/messagebutton.md index 9ec09b65..a1e7dd24 100644 --- a/docs/models/components/messagebutton.md +++ b/docs/models/components/messagebutton.md @@ -6,7 +6,7 @@ import { MessageButton } from "@novu/api/models/components"; let value: MessageButton = { - type: "secondary", + type: "primary", content: "", }; ``` diff --git a/docs/models/components/messagecta.md b/docs/models/components/messagecta.md index 956cbe44..4153ef7a 100644 --- a/docs/models/components/messagecta.md +++ b/docs/models/components/messagecta.md @@ -5,9 +5,7 @@ ```typescript import { MessageCTA } from "@novu/api/models/components"; -let value: MessageCTA = { - data: {}, -}; +let value: MessageCTA = {}; ``` ## Fields @@ -15,5 +13,5 @@ let value: MessageCTA = { | Field | Type | Required | Description | | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | | `type` | [components.ChannelCTATypeEnum](../../models/components/channelctatypeenum.md) | :heavy_minus_sign: | Type of call to action | -| `data` | [components.MessageCTAData](../../models/components/messagectadata.md) | :heavy_check_mark: | Data associated with the call to action | +| `data` | [components.MessageCTAData](../../models/components/messagectadata.md) | :heavy_minus_sign: | Data associated with the call to action | | `action` | [components.MessageAction](../../models/components/messageaction.md) | :heavy_minus_sign: | Action associated with the call to action | \ No newline at end of file diff --git a/docs/models/components/messagemarkasrequestdto.md b/docs/models/components/messagemarkasrequestdto.md index 5f27b9f1..ddbfacee 100644 --- a/docs/models/components/messagemarkasrequestdto.md +++ b/docs/models/components/messagemarkasrequestdto.md @@ -6,9 +6,7 @@ import { MessageMarkAsRequestDto } from "@novu/api/models/components"; let value: MessageMarkAsRequestDto = { - messageId: [ - "", - ], + messageId: "", markAs: "seen", }; ``` diff --git a/docs/models/components/messagemarkasrequestdtomarkas.md b/docs/models/components/messagemarkasrequestdtomarkas.md index 8119e9fa..bb8f7782 100644 --- a/docs/models/components/messagemarkasrequestdtomarkas.md +++ b/docs/models/components/messagemarkasrequestdtomarkas.md @@ -5,7 +5,7 @@ ```typescript import { MessageMarkAsRequestDtoMarkAs } from "@novu/api/models/components"; -let value: MessageMarkAsRequestDtoMarkAs = "unread"; +let value: MessageMarkAsRequestDtoMarkAs = "unseen"; ``` ## Values diff --git a/docs/models/components/messageresponsedto.md b/docs/models/components/messageresponsedto.md index 0f9b38e6..e890a75c 100644 --- a/docs/models/components/messageresponsedto.md +++ b/docs/models/components/messageresponsedto.md @@ -13,10 +13,9 @@ let value: MessageResponseDto = { notificationId: "", subscriberId: "", subscriber: { - subscriberId: "", channels: [ { - providerId: "expo", + providerId: "slack", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -34,61 +33,102 @@ let value: MessageResponseDto = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1727713131699", - updatedAt: "1743435571162", + createdAt: "1727131120553", + updatedAt: "1746595336109", }, - createdAt: "1732212240772", - content: { - type: "text", - content: "", + template: { + name: "", + description: "sport afore meal classic coast allegation pantyhose", + active: false, + draft: false, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + critical: false, + tags: [ + "", + ], + steps: [ + {}, + ], + organizationId: "", + creatorId: "", + environmentId: "", + triggers: [ + { + type: "event", + identifier: "", + variables: [ + { + name: "", + }, + ], + }, + ], + notificationGroupId: "", + deleted: false, + deletedAt: "", + deletedBy: "", }, + createdAt: "1718141577685", + content: [ + { + type: "text", + content: "", + }, + ], transactionId: "", - channel: "in_app", + channel: "push", read: false, seen: false, - cta: { - data: {}, - }, - status: "sent", + cta: {}, + status: "error", }; ``` ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | -| `id` | *string* | :heavy_minus_sign: | Unique identifier for the message | -| `templateId` | *string* | :heavy_check_mark: | Template ID associated with the message | -| `environmentId` | *string* | :heavy_check_mark: | Environment ID where the message is sent | -| `messageTemplateId` | *string* | :heavy_check_mark: | Message template ID | -| `organizationId` | *string* | :heavy_check_mark: | Organization ID associated with the message | -| `notificationId` | *string* | :heavy_check_mark: | Notification ID associated with the message | -| `subscriberId` | *string* | :heavy_check_mark: | Subscriber ID associated with the message | -| `subscriber` | [components.SubscriberResponseDto](../../models/components/subscriberresponsedto.md) | :heavy_minus_sign: | Subscriber details, if available | -| `template` | [components.WorkflowResponse](../../models/components/workflowresponse.md) | :heavy_minus_sign: | Workflow template associated with the message | -| `templateIdentifier` | *string* | :heavy_minus_sign: | Identifier for the message template | -| `createdAt` | *string* | :heavy_check_mark: | Creation date of the message | -| `lastSeenDate` | *string* | :heavy_minus_sign: | Last seen date of the message, if available | -| `lastReadDate` | *string* | :heavy_minus_sign: | Last read date of the message, if available | -| `content` | *components.Content* | :heavy_check_mark: | Content of the message, can be an email block or a string | -| `transactionId` | *string* | :heavy_check_mark: | Transaction ID associated with the message | -| `subject` | *string* | :heavy_minus_sign: | Subject of the message, if applicable | -| `channel` | [components.ChannelTypeEnum](../../models/components/channeltypeenum.md) | :heavy_check_mark: | Channel type through which the message is sent | -| `read` | *boolean* | :heavy_check_mark: | Indicates if the message has been read | -| `seen` | *boolean* | :heavy_check_mark: | Indicates if the message has been seen | -| `email` | *string* | :heavy_minus_sign: | Email address associated with the message, if applicable | -| `phone` | *string* | :heavy_minus_sign: | Phone number associated with the message, if applicable | -| `directWebhookUrl` | *string* | :heavy_minus_sign: | Direct webhook URL for the message, if applicable | -| `providerId` | *string* | :heavy_minus_sign: | Provider ID associated with the message, if applicable | -| `deviceTokens` | *string*[] | :heavy_minus_sign: | Device tokens associated with the message, if applicable | -| `title` | *string* | :heavy_minus_sign: | Title of the message, if applicable | -| `cta` | [components.MessageCTA](../../models/components/messagecta.md) | :heavy_check_mark: | Call to action associated with the message | -| `feedId` | *string* | :heavy_minus_sign: | Feed ID associated with the message, if applicable | -| `status` | [components.MessageStatusEnum](../../models/components/messagestatusenum.md) | :heavy_check_mark: | Status of the message | -| `errorId` | *string* | :heavy_minus_sign: | Error ID if the message has an error | -| `errorText` | *string* | :heavy_minus_sign: | Error text if the message has an error | -| `payload` | [components.MessageResponseDtoPayload](../../models/components/messageresponsedtopayload.md) | :heavy_minus_sign: | The payload that was used to send the notification trigger | -| `overrides` | [components.MessageResponseDtoOverrides](../../models/components/messageresponsedtooverrides.md) | :heavy_minus_sign: | Provider specific overrides used when triggering the notification | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_minus_sign: | Unique identifier for the message | +| `templateId` | *string* | :heavy_check_mark: | Template ID associated with the message | +| `environmentId` | *string* | :heavy_check_mark: | Environment ID where the message is sent | +| `messageTemplateId` | *string* | :heavy_check_mark: | Message template ID | +| `organizationId` | *string* | :heavy_check_mark: | Organization ID associated with the message | +| `notificationId` | *string* | :heavy_check_mark: | Notification ID associated with the message | +| `subscriberId` | *string* | :heavy_check_mark: | Subscriber ID associated with the message | +| `subscriber` | [components.SubscriberResponseDto](../../models/components/subscriberresponsedto.md) | :heavy_minus_sign: | Subscriber details, if available | +| `template` | [components.WorkflowResponse](../../models/components/workflowresponse.md) | :heavy_minus_sign: | Workflow template associated with the message | +| `templateIdentifier` | *string* | :heavy_minus_sign: | Identifier for the message template | +| `createdAt` | *string* | :heavy_check_mark: | Creation date of the message | +| `deliveredAt` | *string*[] | :heavy_minus_sign: | Array of delivery dates for the message, if the message has multiple delivery dates, for example after being snoozed | +| `lastSeenDate` | *string* | :heavy_minus_sign: | Last seen date of the message, if available | +| `lastReadDate` | *string* | :heavy_minus_sign: | Last read date of the message, if available | +| `content` | *components.Content* | :heavy_check_mark: | Content of the message, can be an email block or a string | +| `transactionId` | *string* | :heavy_check_mark: | Transaction ID associated with the message | +| `subject` | *string* | :heavy_minus_sign: | Subject of the message, if applicable | +| `channel` | [components.ChannelTypeEnum](../../models/components/channeltypeenum.md) | :heavy_check_mark: | Channel type through which the message is sent | +| `read` | *boolean* | :heavy_check_mark: | Indicates if the message has been read | +| `seen` | *boolean* | :heavy_check_mark: | Indicates if the message has been seen | +| `snoozedUntil` | *string* | :heavy_minus_sign: | Date when the message will be unsnoozed | +| `email` | *string* | :heavy_minus_sign: | Email address associated with the message, if applicable | +| `phone` | *string* | :heavy_minus_sign: | Phone number associated with the message, if applicable | +| `directWebhookUrl` | *string* | :heavy_minus_sign: | Direct webhook URL for the message, if applicable | +| `providerId` | *string* | :heavy_minus_sign: | Provider ID associated with the message, if applicable | +| `deviceTokens` | *string*[] | :heavy_minus_sign: | Device tokens associated with the message, if applicable | +| `title` | *string* | :heavy_minus_sign: | Title of the message, if applicable | +| `cta` | [components.MessageCTA](../../models/components/messagecta.md) | :heavy_check_mark: | Call to action associated with the message | +| `feedId` | *string* | :heavy_minus_sign: | Feed ID associated with the message, if applicable | +| `status` | [components.MessageStatusEnum](../../models/components/messagestatusenum.md) | :heavy_check_mark: | Status of the message | +| `errorId` | *string* | :heavy_minus_sign: | Error ID if the message has an error | +| `errorText` | *string* | :heavy_minus_sign: | Error text if the message has an error | +| `payload` | [components.MessageResponseDtoPayload](../../models/components/messageresponsedtopayload.md) | :heavy_minus_sign: | The payload that was used to send the notification trigger | +| `overrides` | [components.MessageResponseDtoOverrides](../../models/components/messageresponsedtooverrides.md) | :heavy_minus_sign: | Provider specific overrides used when triggering the notification | \ No newline at end of file diff --git a/docs/models/components/messagesresponsedto.md b/docs/models/components/messagesresponsedto.md new file mode 100644 index 00000000..9e0e3054 --- /dev/null +++ b/docs/models/components/messagesresponsedto.md @@ -0,0 +1,112 @@ +# MessagesResponseDto + +## Example Usage + +```typescript +import { MessagesResponseDto } from "@novu/api/models/components"; + +let value: MessagesResponseDto = { + hasMore: false, + data: [ + { + templateId: "", + environmentId: "", + messageTemplateId: "", + organizationId: "", + notificationId: "", + subscriberId: "", + subscriber: { + channels: [ + { + providerId: "mattermost", + credentials: { + webhookUrl: "https://example.com/webhook", + channel: "general", + deviceTokens: [ + "token1", + "token2", + "token3", + ], + alertUid: "12345-abcde", + title: "Critical Alert", + imageUrl: "https://example.com/image.png", + state: "resolved", + externalUrl: "https://example.com/details", + }, + integrationId: "", + }, + ], + subscriberId: "", + organizationId: "", + environmentId: "", + deleted: false, + createdAt: "1716482745901", + updatedAt: "1746644002946", + }, + template: { + name: "", + description: "probate when likewise", + active: false, + draft: false, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + critical: false, + tags: [ + "", + ], + steps: [ + {}, + ], + organizationId: "", + creatorId: "", + environmentId: "", + triggers: [ + { + type: "event", + identifier: "", + variables: [ + { + name: "", + }, + ], + }, + ], + notificationGroupId: "", + deleted: false, + deletedAt: "", + deletedBy: "", + }, + createdAt: "1715230250808", + content: [ + { + type: "button", + content: "", + }, + ], + transactionId: "", + channel: "chat", + read: false, + seen: false, + cta: {}, + status: "sent", + }, + ], + pageSize: 8224.89, + page: 7670.01, +}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `totalCount` | *number* | :heavy_minus_sign: | Total number of messages available | +| `hasMore` | *boolean* | :heavy_check_mark: | Indicates if there are more messages available | +| `data` | [components.MessageResponseDto](../../models/components/messageresponsedto.md)[] | :heavy_check_mark: | List of messages | +| `pageSize` | *number* | :heavy_check_mark: | Number of messages per page | +| `page` | *number* | :heavy_check_mark: | Current page number | \ No newline at end of file diff --git a/docs/models/components/metadata.md b/docs/models/components/metadata.md index f25a99a2..25c42030 100644 --- a/docs/models/components/metadata.md +++ b/docs/models/components/metadata.md @@ -1,16 +1,40 @@ # Metadata -Metadata for the workflow step +Metadata associated with the workflow step. Can vary based on the type of step. -## Example Usage + +## Supported Types + +### `components.DigestRegularMetadata` + +```typescript +const value: components.DigestRegularMetadata = { + type: "regular", +}; +``` + +### `components.DigestTimedMetadata` ```typescript -import { Metadata } from "@novu/api/models/components"; +const value: components.DigestTimedMetadata = { + type: "timed", +}; +``` + +### `components.DelayRegularMetadata` -let value: Metadata = {}; +```typescript +const value: components.DelayRegularMetadata = { + type: "regular", +}; ``` -## Fields +### `components.DelayScheduledMetadata` + +```typescript +const value: components.DelayScheduledMetadata = { + type: "scheduled", + delayPath: "", +}; +``` -| Field | Type | Required | Description | -| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/components/monthlytype.md b/docs/models/components/monthlytype.md index 3113ba7f..8b6ac551 100644 --- a/docs/models/components/monthlytype.md +++ b/docs/models/components/monthlytype.md @@ -5,7 +5,7 @@ ```typescript import { MonthlyType } from "@novu/api/models/components"; -let value: MonthlyType = "each"; +let value: MonthlyType = "on"; ``` ## Values diff --git a/docs/models/components/notificationfeeditemdto.md b/docs/models/components/notificationfeeditemdto.md index c6b76d0b..dedff49b 100644 --- a/docs/models/components/notificationfeeditemdto.md +++ b/docs/models/components/notificationfeeditemdto.md @@ -19,24 +19,21 @@ let value: NotificationFeedItemDto = { updatedAt: new Date("2024-12-10T10:10:59.639Z"), actor: { data: null, - type: "system_custom", + type: "none", }, transactionId: "transaction_123456", templateIdentifier: "template_abcdef", providerId: "provider_xyz", content: "This is a test notification content.", subject: "Test Notification Subject", - channel: "chat", + channel: "email", read: false, seen: true, - deleted: false, deviceTokens: [ "token1", "token2", ], - cta: { - data: {}, - }, + cta: {}, status: "sent", payload: { "key": "value", @@ -72,7 +69,6 @@ let value: NotificationFeedItemDto = { | `channel` | [components.ChannelTypeEnum](../../models/components/channeltypeenum.md) | :heavy_check_mark: | Channel type through which the message is sent | | | `read` | *boolean* | :heavy_check_mark: | Indicates whether the notification has been read by the subscriber. | false | | `seen` | *boolean* | :heavy_check_mark: | Indicates whether the notification has been seen by the subscriber. | true | -| `deleted` | *boolean* | :heavy_check_mark: | Indicates whether the notification has been deleted. | false | | `deviceTokens` | *string*[] | :heavy_minus_sign: | Device tokens for push notifications, if applicable. | [
"token1",
"token2"
] | | `cta` | [components.MessageCTA](../../models/components/messagecta.md) | :heavy_check_mark: | Call-to-action information associated with the notification. | | | `status` | [components.NotificationFeedItemDtoStatus](../../models/components/notificationfeeditemdtostatus.md) | :heavy_check_mark: | Current status of the notification. | sent | diff --git a/docs/models/components/notificationstepdto.md b/docs/models/components/notificationstepdto.md index 0dcaf535..783f4b74 100644 --- a/docs/models/components/notificationstepdto.md +++ b/docs/models/components/notificationstepdto.md @@ -21,6 +21,6 @@ let value: NotificationStepDto = {}; | `template` | [components.MessageTemplate](../../models/components/messagetemplate.md) | :heavy_minus_sign: | Message template used in this notification step. | | `filters` | [components.StepFilterDto](../../models/components/stepfilterdto.md)[] | :heavy_minus_sign: | Filters applied to this notification step. | | `parentId` | *string* | :heavy_minus_sign: | ID of the parent notification step, if applicable. | -| `metadata` | *components.NotificationStepDtoMetadata* | :heavy_minus_sign: | Metadata associated with the workflow step. Can vary based on the type of step. | +| `metadata` | *components.Metadata* | :heavy_minus_sign: | Metadata associated with the workflow step. Can vary based on the type of step. | | `replyCallback` | [components.ReplyCallback](../../models/components/replycallback.md) | :heavy_minus_sign: | Callback information for replies, including whether it is active and the callback URL. | | `variants` | [components.NotificationStepData](../../models/components/notificationstepdata.md)[] | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/notificationstepdtometadata.md b/docs/models/components/notificationstepdtometadata.md deleted file mode 100644 index e11e5411..00000000 --- a/docs/models/components/notificationstepdtometadata.md +++ /dev/null @@ -1,40 +0,0 @@ -# NotificationStepDtoMetadata - -Metadata associated with the workflow step. Can vary based on the type of step. - - -## Supported Types - -### `components.DigestRegularMetadata` - -```typescript -const value: components.DigestRegularMetadata = { - type: "backoff", -}; -``` - -### `components.DigestTimedMetadata` - -```typescript -const value: components.DigestTimedMetadata = { - type: "timed", -}; -``` - -### `components.DelayRegularMetadata` - -```typescript -const value: components.DelayRegularMetadata = { - type: "regular", -}; -``` - -### `components.DelayScheduledMetadata` - -```typescript -const value: components.DelayScheduledMetadata = { - type: "scheduled", - delayPath: "", -}; -``` - diff --git a/docs/models/components/notificationtriggerdto.md b/docs/models/components/notificationtriggerdto.md index 2cd488f4..3df9abd7 100644 --- a/docs/models/components/notificationtriggerdto.md +++ b/docs/models/components/notificationtriggerdto.md @@ -20,7 +20,7 @@ let value: NotificationTriggerDto = { | Field | Type | Required | Description | | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -| `type` | [components.Type](../../models/components/type.md) | :heavy_check_mark: | Type of the trigger | +| `type` | [components.NotificationTriggerDtoType](../../models/components/notificationtriggerdtotype.md) | :heavy_check_mark: | Type of the trigger | | `identifier` | *string* | :heavy_check_mark: | Identifier of the trigger | | `variables` | [components.NotificationTriggerVariable](../../models/components/notificationtriggervariable.md)[] | :heavy_check_mark: | Variables of the trigger | | `subscriberVariables` | [components.NotificationTriggerVariable](../../models/components/notificationtriggervariable.md)[] | :heavy_minus_sign: | Subscriber variables of the trigger | \ No newline at end of file diff --git a/docs/models/components/notificationtriggerdtotype.md b/docs/models/components/notificationtriggerdtotype.md new file mode 100644 index 00000000..cc99f1bc --- /dev/null +++ b/docs/models/components/notificationtriggerdtotype.md @@ -0,0 +1,17 @@ +# NotificationTriggerDtoType + +Type of the trigger + +## Example Usage + +```typescript +import { NotificationTriggerDtoType } from "@novu/api/models/components"; + +let value: NotificationTriggerDtoType = "event"; +``` + +## Values + +```typescript +"event" +``` \ No newline at end of file diff --git a/docs/models/components/on.md b/docs/models/components/on.md index 3f67d3c1..26cb236e 100644 --- a/docs/models/components/on.md +++ b/docs/models/components/on.md @@ -5,7 +5,7 @@ ```typescript import { On } from "@novu/api/models/components"; -let value: On = "payload"; +let value: On = "subscriber"; ``` ## Values diff --git a/docs/models/components/operator.md b/docs/models/components/operator.md index dbbf67fb..9975bb13 100644 --- a/docs/models/components/operator.md +++ b/docs/models/components/operator.md @@ -5,7 +5,7 @@ ```typescript import { Operator } from "@novu/api/models/components"; -let value: Operator = "SMALLER_EQUAL"; +let value: Operator = "ANY_IN"; ``` ## Values diff --git a/docs/models/components/ordinal.md b/docs/models/components/ordinal.md index ebaddb3c..c1c4601c 100644 --- a/docs/models/components/ordinal.md +++ b/docs/models/components/ordinal.md @@ -5,7 +5,7 @@ ```typescript import { Ordinal } from "@novu/api/models/components"; -let value: Ordinal = "3"; +let value: Ordinal = "last"; ``` ## Values diff --git a/docs/models/components/ordinalenum.md b/docs/models/components/ordinalenum.md index 0245be01..73a8faa2 100644 --- a/docs/models/components/ordinalenum.md +++ b/docs/models/components/ordinalenum.md @@ -7,7 +7,7 @@ Ordinal position for the digest ```typescript import { OrdinalEnum } from "@novu/api/models/components"; -let value: OrdinalEnum = "1"; +let value: OrdinalEnum = "4"; ``` ## Values diff --git a/docs/models/components/ordinalvalue.md b/docs/models/components/ordinalvalue.md index 922da211..31c73e0b 100644 --- a/docs/models/components/ordinalvalue.md +++ b/docs/models/components/ordinalvalue.md @@ -5,7 +5,7 @@ ```typescript import { OrdinalValue } from "@novu/api/models/components"; -let value: OrdinalValue = "weekday"; +let value: OrdinalValue = "saturday"; ``` ## Values diff --git a/docs/models/components/ordinalvalueenum.md b/docs/models/components/ordinalvalueenum.md index 8184fe67..b415b9eb 100644 --- a/docs/models/components/ordinalvalueenum.md +++ b/docs/models/components/ordinalvalueenum.md @@ -7,7 +7,7 @@ Value of the ordinal ```typescript import { OrdinalValueEnum } from "@novu/api/models/components"; -let value: OrdinalValueEnum = "weekend"; +let value: OrdinalValueEnum = "wednesday"; ``` ## Values diff --git a/docs/models/components/overrides.md b/docs/models/components/overrides.md index 821f13a5..b8b2fa5c 100644 --- a/docs/models/components/overrides.md +++ b/docs/models/components/overrides.md @@ -1,19 +1,23 @@ # Overrides +This could be used to override provider specific configurations + ## Example Usage ```typescript import { Overrides } from "@novu/api/models/components"; -let value: Overrides = { - channel: "email", - source: "workflowOverride", -}; +let value: Overrides = {}; ``` ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- | -| `channel` | [components.Channel](../../models/components/channel.md) | :heavy_check_mark: | The channel type which is overridden | -| `source` | [components.Source](../../models/components/source.md) | :heavy_check_mark: | The source of overrides | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `steps` | Record | :heavy_minus_sign: | This could be used to override provider specific configurations | {
"email-step": {
"providers": {
"sendgrid": {
"templateId": "1234567890"
}
}
}
} | +| `providers` | Record> | :heavy_minus_sign: | Overrides the provider configuration for the entire workflow and all steps | {
"sendgrid": {
"templateId": "1234567890"
}
} | +| ~~`email`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the email provider specific configurations for the entire workflow | | +| ~~`push`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the push provider specific configurations for the entire workflow | | +| ~~`sms`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the sms provider specific configurations for the entire workflow | | +| ~~`chat`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the chat provider specific configurations for the entire workflow | | +| ~~`layoutIdentifier`~~ | *string* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the layout identifier for the entire workflow | | \ No newline at end of file diff --git a/docs/models/components/patchsubscriberpreferencesdto.md b/docs/models/components/patchsubscriberpreferencesdto.md index aafecbca..55bb0d4d 100644 --- a/docs/models/components/patchsubscriberpreferencesdto.md +++ b/docs/models/components/patchsubscriberpreferencesdto.md @@ -12,7 +12,7 @@ let value: PatchSubscriberPreferencesDto = { ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | -| `channels` | [components.PatchPreferenceChannelsDto](../../models/components/patchpreferencechannelsdto.md) | :heavy_check_mark: | Channel-specific preference settings | -| `workflowId` | *string* | :heavy_minus_sign: | If provided, update workflow specific preferences, otherwise update global preferences | \ No newline at end of file +| Field | Type | Required | Description | +| --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | +| `channels` | [components.PatchPreferenceChannelsDto](../../models/components/patchpreferencechannelsdto.md) | :heavy_check_mark: | Channel-specific preference settings | +| `workflowId` | *string* | :heavy_minus_sign: | Workflow internal _id, identifier or slug. If provided, update workflow specific preferences, otherwise update global preferences | \ No newline at end of file diff --git a/docs/models/components/payload.md b/docs/models/components/payload.md index 919c262a..a795bfe7 100644 --- a/docs/models/components/payload.md +++ b/docs/models/components/payload.md @@ -1,6 +1,6 @@ # Payload -Optional payload for the job +Payload of the action result ## Example Usage diff --git a/docs/models/components/preferencechannels.md b/docs/models/components/preferencechannels.md deleted file mode 100644 index f6df176a..00000000 --- a/docs/models/components/preferencechannels.md +++ /dev/null @@ -1,19 +0,0 @@ -# PreferenceChannels - -## Example Usage - -```typescript -import { PreferenceChannels } from "@novu/api/models/components"; - -let value: PreferenceChannels = {}; -``` - -## Fields - -| Field | Type | Required | Description | -| ------------------ | ------------------ | ------------------ | ------------------ | -| `email` | *boolean* | :heavy_minus_sign: | N/A | -| `sms` | *boolean* | :heavy_minus_sign: | N/A | -| `inApp` | *boolean* | :heavy_minus_sign: | N/A | -| `chat` | *boolean* | :heavy_minus_sign: | N/A | -| `push` | *boolean* | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/preferenceoverridesourceenum.md b/docs/models/components/preferenceoverridesourceenum.md new file mode 100644 index 00000000..ab1e2b00 --- /dev/null +++ b/docs/models/components/preferenceoverridesourceenum.md @@ -0,0 +1,17 @@ +# PreferenceOverrideSourceEnum + +The source of overrides + +## Example Usage + +```typescript +import { PreferenceOverrideSourceEnum } from "@novu/api/models/components"; + +let value: PreferenceOverrideSourceEnum = "template"; +``` + +## Values + +```typescript +"subscriber" | "template" | "workflowOverride" +``` \ No newline at end of file diff --git a/docs/models/components/providerid.md b/docs/models/components/providerid.md index fe244265..ad171b0c 100644 --- a/docs/models/components/providerid.md +++ b/docs/models/components/providerid.md @@ -1,13 +1,13 @@ # ProviderId -The provider identifier for the credentials +The ID of the chat or push provider. ## Example Usage ```typescript import { ProviderId } from "@novu/api/models/components"; -let value: ProviderId = "whatsapp-business"; +let value: ProviderId = "ryver"; ``` ## Values diff --git a/docs/models/components/providersidenum.md b/docs/models/components/providersidenum.md index 565d9fbf..9b1be348 100644 --- a/docs/models/components/providersidenum.md +++ b/docs/models/components/providersidenum.md @@ -7,11 +7,11 @@ Provider ID of the job ```typescript import { ProvidersIdEnum } from "@novu/api/models/components"; -let value: ProvidersIdEnum = "novu-sms"; +let value: ProvidersIdEnum = "plivo"; ``` ## Values ```typescript -"emailjs" | "mailgun" | "mailjet" | "mandrill" | "nodemailer" | "postmark" | "sendgrid" | "sendinblue" | "ses" | "netcore" | "infobip-email" | "resend" | "plunk" | "mailersend" | "mailtrap" | "clickatell" | "outlook365" | "novu-email" | "sparkpost" | "email-webhook" | "braze" | "nexmo" | "plivo" | "sms77" | "sms-central" | "sns" | "telnyx" | "twilio" | "gupshup" | "firetext" | "infobip-sms" | "burst-sms" | "bulk-sms" | "isend-sms" | "forty-six-elks" | "kannel" | "maqsam" | "termii" | "africas-talking" | "novu-sms" | "sendchamp" | "generic-sms" | "clicksend" | "bandwidth" | "messagebird" | "simpletexting" | "azure-sms" | "ring-central" | "brevo-sms" | "eazy-sms" | "mobishastra" | "fcm" | "apns" | "expo" | "one-signal" | "pushpad" | "push-webhook" | "pusher-beams" | "novu" | "slack" | "discord" | "msteams" | "mattermost" | "ryver" | "zulip" | "grafana-on-call" | "getstream" | "rocket-chat" | "whatsapp-business" +"emailjs" | "mailgun" | "mailjet" | "mandrill" | "nodemailer" | "postmark" | "sendgrid" | "sendinblue" | "ses" | "netcore" | "infobip-email" | "resend" | "plunk" | "mailersend" | "mailtrap" | "clickatell" | "outlook365" | "novu-email" | "sparkpost" | "email-webhook" | "braze" | "nexmo" | "plivo" | "sms77" | "sms-central" | "sns" | "telnyx" | "twilio" | "gupshup" | "firetext" | "infobip-sms" | "burst-sms" | "bulk-sms" | "isend-sms" | "forty-six-elks" | "kannel" | "maqsam" | "termii" | "africas-talking" | "novu-sms" | "sendchamp" | "generic-sms" | "clicksend" | "bandwidth" | "messagebird" | "simpletexting" | "azure-sms" | "ring-central" | "brevo-sms" | "eazy-sms" | "mobishastra" | "afro-message" | "fcm" | "apns" | "expo" | "one-signal" | "pushpad" | "push-webhook" | "pusher-beams" | "novu" | "slack" | "discord" | "msteams" | "mattermost" | "ryver" | "zulip" | "grafana-on-call" | "getstream" | "rocket-chat" | "whatsapp-business" ``` \ No newline at end of file diff --git a/docs/models/components/source.md b/docs/models/components/source.md deleted file mode 100644 index ad4a2a06..00000000 --- a/docs/models/components/source.md +++ /dev/null @@ -1,17 +0,0 @@ -# Source - -The source of overrides - -## Example Usage - -```typescript -import { Source } from "@novu/api/models/components"; - -let value: Source = "workflowOverride"; -``` - -## Values - -```typescript -"subscriber" | "template" | "workflowOverride" -``` \ No newline at end of file diff --git a/docs/models/components/status.md b/docs/models/components/status.md index d435de16..1c9e6b48 100644 --- a/docs/models/components/status.md +++ b/docs/models/components/status.md @@ -7,7 +7,7 @@ Status of the trigger ```typescript import { Status } from "@novu/api/models/components"; -let value: Status = "error"; +let value: Status = "processed"; ``` ## Values diff --git a/docs/models/components/stepfilterdto.md b/docs/models/components/stepfilterdto.md index 3280a6e1..b5f26e9e 100644 --- a/docs/models/components/stepfilterdto.md +++ b/docs/models/components/stepfilterdto.md @@ -8,12 +8,12 @@ import { StepFilterDto } from "@novu/api/models/components"; let value: StepFilterDto = { isNegated: false, type: "NUMBER", - value: "OR", + value: "AND", children: [ { field: "", value: "", - operator: "NOT_LIKE", + operator: "NOT_BETWEEN", on: "payload", }, ], @@ -26,5 +26,5 @@ let value: StepFilterDto = { | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | | `isNegated` | *boolean* | :heavy_check_mark: | N/A | | `type` | [components.BuilderFieldTypeEnum](../../models/components/builderfieldtypeenum.md) | :heavy_check_mark: | N/A | -| `value` | [components.Value](../../models/components/value.md) | :heavy_check_mark: | N/A | +| `value` | [components.StepFilterDtoValue](../../models/components/stepfilterdtovalue.md) | :heavy_check_mark: | N/A | | `children` | [components.FieldFilterPartDto](../../models/components/fieldfilterpartdto.md)[] | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/components/stepfilterdtovalue.md b/docs/models/components/stepfilterdtovalue.md new file mode 100644 index 00000000..918ab4f1 --- /dev/null +++ b/docs/models/components/stepfilterdtovalue.md @@ -0,0 +1,15 @@ +# StepFilterDtoValue + +## Example Usage + +```typescript +import { StepFilterDtoValue } from "@novu/api/models/components"; + +let value: StepFilterDtoValue = "OR"; +``` + +## Values + +```typescript +"AND" | "OR" +``` \ No newline at end of file diff --git a/docs/models/components/stepsoverrides.md b/docs/models/components/stepsoverrides.md new file mode 100644 index 00000000..0ac21213 --- /dev/null +++ b/docs/models/components/stepsoverrides.md @@ -0,0 +1,21 @@ +# StepsOverrides + +## Example Usage + +```typescript +import { StepsOverrides } from "@novu/api/models/components"; + +let value: StepsOverrides = { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, +}; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------- | +| `providers` | Record> | :heavy_check_mark: | Passing the provider id and the provider specific configurations | {
"sendgrid": {
"templateId": "1234567890"
}
} | \ No newline at end of file diff --git a/docs/models/components/steptypeenum.md b/docs/models/components/steptypeenum.md index 6f6e019c..5da9aa9f 100644 --- a/docs/models/components/steptypeenum.md +++ b/docs/models/components/steptypeenum.md @@ -1,13 +1,13 @@ # StepTypeEnum -Channels of the notification +Type of the step ## Example Usage ```typescript import { StepTypeEnum } from "@novu/api/models/components"; -let value: StepTypeEnum = "delay"; +let value: StepTypeEnum = "custom"; ``` ## Values diff --git a/docs/models/components/subscriberchanneldto.md b/docs/models/components/subscriberchanneldto.md index bfa712ba..9ecf1127 100644 --- a/docs/models/components/subscriberchanneldto.md +++ b/docs/models/components/subscriberchanneldto.md @@ -6,15 +6,15 @@ import { SubscriberChannelDto } from "@novu/api/models/components"; let value: SubscriberChannelDto = { - providerId: "whatsapp-business", + providerId: "expo", credentials: {}, }; ``` ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ | -| `providerId` | [components.SubscriberChannelDtoProviderId](../../models/components/subscriberchanneldtoproviderid.md) | :heavy_check_mark: | The ID of the chat or push provider. | -| `integrationIdentifier` | *string* | :heavy_minus_sign: | An optional identifier for the integration. | -| `credentials` | [components.ChannelCredentialsDto](../../models/components/channelcredentialsdto.md) | :heavy_check_mark: | Credentials for the channel. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `providerId` | [components.ProviderId](../../models/components/providerid.md) | :heavy_check_mark: | The ID of the chat or push provider. | +| `integrationIdentifier` | *string* | :heavy_minus_sign: | An optional identifier for the integration. | +| `credentials` | [components.ChannelCredentialsDto](../../models/components/channelcredentialsdto.md) | :heavy_check_mark: | Credentials for the channel. | \ No newline at end of file diff --git a/docs/models/components/subscriberchanneldtoproviderid.md b/docs/models/components/subscriberchanneldtoproviderid.md deleted file mode 100644 index dec45313..00000000 --- a/docs/models/components/subscriberchanneldtoproviderid.md +++ /dev/null @@ -1,17 +0,0 @@ -# SubscriberChannelDtoProviderId - -The ID of the chat or push provider. - -## Example Usage - -```typescript -import { SubscriberChannelDtoProviderId } from "@novu/api/models/components"; - -let value: SubscriberChannelDtoProviderId = "mattermost"; -``` - -## Values - -```typescript -"slack" | "discord" | "msteams" | "mattermost" | "ryver" | "zulip" | "grafana-on-call" | "getstream" | "rocket-chat" | "whatsapp-business" | "fcm" | "apns" | "expo" | "one-signal" | "pushpad" | "push-webhook" | "pusher-beams" -``` \ No newline at end of file diff --git a/docs/models/components/subscriberglobalpreferencedto.md b/docs/models/components/subscriberglobalpreferencedto.md new file mode 100644 index 00000000..c4444dac --- /dev/null +++ b/docs/models/components/subscriberglobalpreferencedto.md @@ -0,0 +1,25 @@ +# SubscriberGlobalPreferenceDto + +## Example Usage + +```typescript +import { SubscriberGlobalPreferenceDto } from "@novu/api/models/components"; + +let value: SubscriberGlobalPreferenceDto = { + enabled: false, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, +}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | +| `enabled` | *boolean* | :heavy_check_mark: | Whether notifications are enabled globally | +| `channels` | [components.SubscriberPreferenceChannels](../../models/components/subscriberpreferencechannels.md) | :heavy_check_mark: | Channel-specific preference settings | \ No newline at end of file diff --git a/docs/models/components/subscriberpayloaddtodata.md b/docs/models/components/subscriberpayloaddtodata.md index 8edcdb23..ac9cd90a 100644 --- a/docs/models/components/subscriberpayloaddtodata.md +++ b/docs/models/components/subscriberpayloaddtodata.md @@ -26,6 +26,6 @@ const value: boolean = false; ### `number` ```typescript -const value: number = 2894.06; +const value: number = 1284.03; ``` diff --git a/docs/models/components/subscriberpreferencechannels.md b/docs/models/components/subscriberpreferencechannels.md new file mode 100644 index 00000000..fa409f5d --- /dev/null +++ b/docs/models/components/subscriberpreferencechannels.md @@ -0,0 +1,25 @@ +# SubscriberPreferenceChannels + +## Example Usage + +```typescript +import { SubscriberPreferenceChannels } from "@novu/api/models/components"; + +let value: SubscriberPreferenceChannels = { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, +}; +``` + +## Fields + +| Field | Type | Required | Description | Example | +| ------------------------------------ | ------------------------------------ | ------------------------------------ | ------------------------------------ | ------------------------------------ | +| `email` | *boolean* | :heavy_minus_sign: | Email channel preference | true | +| `sms` | *boolean* | :heavy_minus_sign: | SMS channel preference | false | +| `inApp` | *boolean* | :heavy_minus_sign: | In-app channel preference | true | +| `chat` | *boolean* | :heavy_minus_sign: | Chat channel preference | false | +| `push` | *boolean* | :heavy_minus_sign: | Push notification channel preference | true | \ No newline at end of file diff --git a/docs/models/components/subscriberpreferenceoverridedto.md b/docs/models/components/subscriberpreferenceoverridedto.md new file mode 100644 index 00000000..c7ff82c1 --- /dev/null +++ b/docs/models/components/subscriberpreferenceoverridedto.md @@ -0,0 +1,19 @@ +# SubscriberPreferenceOverrideDto + +## Example Usage + +```typescript +import { SubscriberPreferenceOverrideDto } from "@novu/api/models/components"; + +let value: SubscriberPreferenceOverrideDto = { + channel: "chat", + source: "subscriber", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | +| `channel` | [components.ChannelTypeEnum](../../models/components/channeltypeenum.md) | :heavy_check_mark: | Channel type through which the message is sent | +| `source` | [components.PreferenceOverrideSourceEnum](../../models/components/preferenceoverridesourceenum.md) | :heavy_check_mark: | The source of overrides | \ No newline at end of file diff --git a/docs/models/components/workflowinfodto.md b/docs/models/components/subscriberpreferencesworkflowinfodto.md similarity index 84% rename from docs/models/components/workflowinfodto.md rename to docs/models/components/subscriberpreferencesworkflowinfodto.md index d77ee2f1..bc7b54fa 100644 --- a/docs/models/components/workflowinfodto.md +++ b/docs/models/components/subscriberpreferencesworkflowinfodto.md @@ -1,11 +1,11 @@ -# WorkflowInfoDto +# SubscriberPreferencesWorkflowInfoDto ## Example Usage ```typescript -import { WorkflowInfoDto } from "@novu/api/models/components"; +import { SubscriberPreferencesWorkflowInfoDto } from "@novu/api/models/components"; -let value: WorkflowInfoDto = { +let value: SubscriberPreferencesWorkflowInfoDto = { slug: "", identifier: "", name: "", diff --git a/docs/models/components/subscriberresponsedto.md b/docs/models/components/subscriberresponsedto.md index e7b42c6e..ca3f6ed8 100644 --- a/docs/models/components/subscriberresponsedto.md +++ b/docs/models/components/subscriberresponsedto.md @@ -6,10 +6,9 @@ import { SubscriberResponseDto } from "@novu/api/models/components"; let value: SubscriberResponseDto = { - subscriberId: "", channels: [ { - providerId: "ryver", + providerId: "slack", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -27,11 +26,12 @@ let value: SubscriberResponseDto = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1730073063470", - updatedAt: "1743404118179", + createdAt: "1721583517098", + updatedAt: "1746655036761", }; ``` @@ -46,16 +46,16 @@ let value: SubscriberResponseDto = { | `phone` | *string* | :heavy_minus_sign: | The phone number of the subscriber. | | `avatar` | *string* | :heavy_minus_sign: | The URL of the subscriber's avatar image. | | `locale` | *string* | :heavy_minus_sign: | The locale setting of the subscriber, indicating their preferred language or region. | -| `subscriberId` | *string* | :heavy_check_mark: | The identifier used to create this subscriber, which typically corresponds to the user ID in your system. | | `channels` | [components.ChannelSettingsDto](../../models/components/channelsettingsdto.md)[] | :heavy_minus_sign: | An array of channel settings associated with the subscriber. | | ~~`topics`~~ | *string*[] | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

An array of topics that the subscriber is subscribed to. | | `isOnline` | *boolean* | :heavy_minus_sign: | Indicates whether the subscriber is currently online. | | `lastOnlineAt` | *string* | :heavy_minus_sign: | The timestamp indicating when the subscriber was last online, in ISO 8601 format. | +| `v` | *number* | :heavy_minus_sign: | The version of the subscriber document. | +| `data` | Record | :heavy_minus_sign: | Additional custom data for the subscriber | +| `timezone` | *string* | :heavy_minus_sign: | Timezone of the subscriber | +| `subscriberId` | *string* | :heavy_check_mark: | The identifier used to create this subscriber, which typically corresponds to the user ID in your system. | | `organizationId` | *string* | :heavy_check_mark: | The unique identifier of the organization to which the subscriber belongs. | | `environmentId` | *string* | :heavy_check_mark: | The unique identifier of the environment associated with this subscriber. | | `deleted` | *boolean* | :heavy_check_mark: | Indicates whether the subscriber has been deleted. | | `createdAt` | *string* | :heavy_check_mark: | The timestamp indicating when the subscriber was created, in ISO 8601 format. | -| `updatedAt` | *string* | :heavy_check_mark: | The timestamp indicating when the subscriber was last updated, in ISO 8601 format. | -| `v` | *number* | :heavy_minus_sign: | The version of the subscriber document. | -| `data` | Record | :heavy_minus_sign: | Additional custom data for the subscriber | -| `timezone` | *string* | :heavy_minus_sign: | Timezone of the subscriber | \ No newline at end of file +| `updatedAt` | *string* | :heavy_check_mark: | The timestamp indicating when the subscriber was last updated, in ISO 8601 format. | \ No newline at end of file diff --git a/docs/models/components/subscriberworkflowpreferencedto.md b/docs/models/components/subscriberworkflowpreferencedto.md new file mode 100644 index 00000000..fac8e495 --- /dev/null +++ b/docs/models/components/subscriberworkflowpreferencedto.md @@ -0,0 +1,38 @@ +# SubscriberWorkflowPreferenceDto + +## Example Usage + +```typescript +import { SubscriberWorkflowPreferenceDto } from "@novu/api/models/components"; + +let value: SubscriberWorkflowPreferenceDto = { + enabled: false, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + overrides: [ + { + channel: "in_app", + source: "template", + }, + ], + workflow: { + slug: "", + identifier: "", + name: "", + }, +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | +| `enabled` | *boolean* | :heavy_check_mark: | Whether notifications are enabled for this workflow | +| `channels` | [components.SubscriberPreferenceChannels](../../models/components/subscriberpreferencechannels.md) | :heavy_check_mark: | Channel-specific preference settings for this workflow | +| `overrides` | [components.SubscriberPreferenceOverrideDto](../../models/components/subscriberpreferenceoverridedto.md)[] | :heavy_check_mark: | List of preference overrides | +| `workflow` | [components.SubscriberPreferencesWorkflowInfoDto](../../models/components/subscriberpreferencesworkflowinfodto.md) | :heavy_check_mark: | Workflow information | \ No newline at end of file diff --git a/docs/models/components/textalignenum.md b/docs/models/components/textalignenum.md index cffa8b9b..18e789e4 100644 --- a/docs/models/components/textalignenum.md +++ b/docs/models/components/textalignenum.md @@ -7,7 +7,7 @@ Text alignment for the email block ```typescript import { TextAlignEnum } from "@novu/api/models/components"; -let value: TextAlignEnum = "left"; +let value: TextAlignEnum = "right"; ``` ## Values diff --git a/docs/models/components/timedconfig.md b/docs/models/components/timedconfig.md index 1362c453..201d9d7e 100644 --- a/docs/models/components/timedconfig.md +++ b/docs/models/components/timedconfig.md @@ -10,11 +10,11 @@ let value: TimedConfig = {}; ## Fields -| Field | Type | Required | Description | -| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | -| `atTime` | *string* | :heavy_minus_sign: | N/A | -| `weekDays` | [components.TimedConfigWeekDays](../../models/components/timedconfigweekdays.md)[] | :heavy_minus_sign: | N/A | -| `monthDays` | *string*[] | :heavy_minus_sign: | N/A | -| `ordinal` | [components.Ordinal](../../models/components/ordinal.md) | :heavy_minus_sign: | N/A | -| `ordinalValue` | [components.OrdinalValue](../../models/components/ordinalvalue.md) | :heavy_minus_sign: | N/A | -| `monthlyType` | [components.MonthlyType](../../models/components/monthlytype.md) | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | +| `atTime` | *string* | :heavy_minus_sign: | N/A | +| `weekDays` | [components.WeekDays](../../models/components/weekdays.md)[] | :heavy_minus_sign: | N/A | +| `monthDays` | *string*[] | :heavy_minus_sign: | N/A | +| `ordinal` | [components.Ordinal](../../models/components/ordinal.md) | :heavy_minus_sign: | N/A | +| `ordinalValue` | [components.OrdinalValue](../../models/components/ordinalvalue.md) | :heavy_minus_sign: | N/A | +| `monthlyType` | [components.MonthlyType](../../models/components/monthlytype.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/timedconfigweekdays.md b/docs/models/components/timedconfigweekdays.md deleted file mode 100644 index 9ddfaf97..00000000 --- a/docs/models/components/timedconfigweekdays.md +++ /dev/null @@ -1,15 +0,0 @@ -# TimedConfigWeekDays - -## Example Usage - -```typescript -import { TimedConfigWeekDays } from "@novu/api/models/components"; - -let value: TimedConfigWeekDays = "friday"; -``` - -## Values - -```typescript -"monday" | "tuesday" | "wednesday" | "thursday" | "friday" | "saturday" | "sunday" -``` \ No newline at end of file diff --git a/docs/models/components/to.md b/docs/models/components/to.md index 69b958ae..4c8fc02a 100644 --- a/docs/models/components/to.md +++ b/docs/models/components/to.md @@ -9,9 +9,7 @@ The recipients list of people who will receive the notification. ```typescript const value: components.One[] = [ - { - subscriberId: "", - }, + "SUBSCRIBER_ID", ]; ``` diff --git a/docs/models/components/topicpayloaddto.md b/docs/models/components/topicpayloaddto.md index 919e5d80..6b38a0a5 100644 --- a/docs/models/components/topicpayloaddto.md +++ b/docs/models/components/topicpayloaddto.md @@ -7,7 +7,7 @@ import { TopicPayloadDto } from "@novu/api/models/components"; let value: TopicPayloadDto = { topicKey: "", - type: "Subscriber", + type: "Topic", }; ``` diff --git a/docs/models/components/triggereventrequestdto.md b/docs/models/components/triggereventrequestdto.md index eef616a9..8e4cc854 100644 --- a/docs/models/components/triggereventrequestdto.md +++ b/docs/models/components/triggereventrequestdto.md @@ -13,16 +13,8 @@ let value: TriggerEventRequestDto = { "text": "string", }, }, - overrides: { - "fcm": { - "data": { - "key": "value", - }, - }, - }, - to: [ - "SUBSCRIBER_ID", - ], + overrides: {}, + to: "SUBSCRIBER_ID", }; ``` @@ -32,7 +24,7 @@ let value: TriggerEventRequestDto = { | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | `workflowId` | *string* | :heavy_check_mark: | The trigger identifier of the workflow you wish to send. This identifier can be found on the workflow page. | workflow_identifier | | `payload` | Record | :heavy_minus_sign: | The payload object is used to pass additional custom information that could be
used to render the workflow, or perform routing rules based on it.
This data will also be available when fetching the notifications feed from the API to display certain parts of the UI. | {
"comment_id": "string",
"post": {
"text": "string"
}
} | -| `overrides` | Record> | :heavy_minus_sign: | This could be used to override provider specific configurations | {
"fcm": {
"data": {
"key": "value"
}
}
} | +| `overrides` | [components.Overrides](../../models/components/overrides.md) | :heavy_minus_sign: | This could be used to override provider specific configurations | {
"fcm": {
"data": {
"key": "value"
}
}
} | | `to` | *components.To* | :heavy_check_mark: | The recipients list of people who will receive the notification. | | | `transactionId` | *string* | :heavy_minus_sign: | A unique identifier for this transaction, we will generate a UUID if not provided. | | | `actor` | *components.Actor* | :heavy_minus_sign: | It is used to display the Avatar of the provided actor's subscriber id or actor object.
If a new actor object is provided, we will create a new subscriber in our system | | diff --git a/docs/models/components/triggereventresponsedto.md b/docs/models/components/triggereventresponsedto.md index d4e4ebaf..b1130b3d 100644 --- a/docs/models/components/triggereventresponsedto.md +++ b/docs/models/components/triggereventresponsedto.md @@ -7,7 +7,7 @@ import { TriggerEventResponseDto } from "@novu/api/models/components"; let value: TriggerEventResponseDto = { acknowledged: false, - status: "processed", + status: "invalid_recipients", }; ``` diff --git a/docs/models/components/triggereventtoallrequestdto.md b/docs/models/components/triggereventtoallrequestdto.md index fc43b6c5..32705ed4 100644 --- a/docs/models/components/triggereventtoallrequestdto.md +++ b/docs/models/components/triggereventtoallrequestdto.md @@ -13,7 +13,15 @@ let value: TriggerEventToAllRequestDto = { "text": "string", }, }, - overrides: {}, + overrides: { + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }; ``` diff --git a/docs/models/components/triggereventtoallrequestdtooverrides.md b/docs/models/components/triggereventtoallrequestdtooverrides.md index 89918b67..6d8c6650 100644 --- a/docs/models/components/triggereventtoallrequestdtooverrides.md +++ b/docs/models/components/triggereventtoallrequestdtooverrides.md @@ -7,10 +7,26 @@ This could be used to override provider specific configurations ```typescript import { TriggerEventToAllRequestDtoOverrides } from "@novu/api/models/components"; -let value: TriggerEventToAllRequestDtoOverrides = {}; +let value: TriggerEventToAllRequestDtoOverrides = { + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, +}; ``` ## Fields -| Field | Type | Required | Description | -| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file +| Field | Type | Required | Description | Example | +| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `steps` | Record | :heavy_minus_sign: | This could be used to override provider specific configurations | {
"email-step": {
"providers": {
"sendgrid": {
"templateId": "1234567890"
}
}
}
} | +| `providers` | Record> | :heavy_minus_sign: | Overrides the provider configuration for the entire workflow and all steps | {
"sendgrid": {
"templateId": "1234567890"
}
} | +| ~~`email`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the email provider specific configurations for the entire workflow | | +| ~~`push`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the push provider specific configurations for the entire workflow | | +| ~~`sms`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the sms provider specific configurations for the entire workflow | | +| ~~`chat`~~ | Record | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the chat provider specific configurations for the entire workflow | | +| ~~`layoutIdentifier`~~ | *string* | :heavy_minus_sign: | : warning: ** DEPRECATED **: This will be removed in a future release, please migrate away from it as soon as possible.

Override the layout identifier for the entire workflow | | +| `additionalProperties` | Record> | :heavy_minus_sign: | N/A | {
"fcm": {
"data": {
"key": "value"
}
}
} | \ No newline at end of file diff --git a/docs/models/components/triggerrecipientstypeenum.md b/docs/models/components/triggerrecipientstypeenum.md index 51c9abf9..61422362 100644 --- a/docs/models/components/triggerrecipientstypeenum.md +++ b/docs/models/components/triggerrecipientstypeenum.md @@ -5,7 +5,7 @@ ```typescript import { TriggerRecipientsTypeEnum } from "@novu/api/models/components"; -let value: TriggerRecipientsTypeEnum = "Topic"; +let value: TriggerRecipientsTypeEnum = "Subscriber"; ``` ## Values diff --git a/docs/models/components/type.md b/docs/models/components/type.md index fafdda19..315a2192 100644 --- a/docs/models/components/type.md +++ b/docs/models/components/type.md @@ -1,17 +1,15 @@ # Type -Type of the trigger - ## Example Usage ```typescript import { Type } from "@novu/api/models/components"; -let value: Type = "event"; +let value: Type = "regular"; ``` ## Values ```typescript -"event" +"regular" | "backoff" ``` \ No newline at end of file diff --git a/docs/models/components/unit.md b/docs/models/components/unit.md index 0aa5b453..c493c406 100644 --- a/docs/models/components/unit.md +++ b/docs/models/components/unit.md @@ -1,13 +1,11 @@ # Unit -Unit of the digest - ## Example Usage ```typescript import { Unit } from "@novu/api/models/components"; -let value: Unit = "days"; +let value: Unit = "weeks"; ``` ## Values diff --git a/docs/models/components/unseencountresponse.md b/docs/models/components/unseencountresponse.md index 46ab6d3c..bd5f53db 100644 --- a/docs/models/components/unseencountresponse.md +++ b/docs/models/components/unseencountresponse.md @@ -6,7 +6,7 @@ import { UnseenCountResponse } from "@novu/api/models/components"; let value: UnseenCountResponse = { - count: 7308.56, + count: 8956.81, }; ``` diff --git a/docs/models/components/updatesubscriberchannelrequestdto.md b/docs/models/components/updatesubscriberchannelrequestdto.md index bc1efa95..eb1ddc8d 100644 --- a/docs/models/components/updatesubscriberchannelrequestdto.md +++ b/docs/models/components/updatesubscriberchannelrequestdto.md @@ -6,7 +6,7 @@ import { UpdateSubscriberChannelRequestDto } from "@novu/api/models/components"; let value: UpdateSubscriberChannelRequestDto = { - providerId: "pushpad", + providerId: "getstream", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -26,8 +26,8 @@ let value: UpdateSubscriberChannelRequestDto = { ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | -| `providerId` | [components.UpdateSubscriberChannelRequestDtoProviderId](../../models/components/updatesubscriberchannelrequestdtoproviderid.md) | :heavy_check_mark: | The provider identifier for the credentials | -| `integrationIdentifier` | *string* | :heavy_minus_sign: | The integration identifier | -| `credentials` | [components.ChannelCredentials](../../models/components/channelcredentials.md) | :heavy_check_mark: | Credentials payload for the specified provider | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------- | +| `providerId` | [components.ChatOrPushProviderEnum](../../models/components/chatorpushproviderenum.md) | :heavy_check_mark: | The provider identifier for the credentials | +| `integrationIdentifier` | *string* | :heavy_minus_sign: | The integration identifier | +| `credentials` | [components.ChannelCredentials](../../models/components/channelcredentials.md) | :heavy_check_mark: | Credentials payload for the specified provider | \ No newline at end of file diff --git a/docs/models/components/value.md b/docs/models/components/value.md index b9f79c7e..7bddf4d7 100644 --- a/docs/models/components/value.md +++ b/docs/models/components/value.md @@ -1,15 +1,39 @@ # Value -## Example Usage +Value that failed validation + + +## Supported Types + +### `string` + +```typescript +const value: string = "xx xx xx "; +``` + +### `number` + +```typescript +const value: number = xx xx xx ; +``` + +### `boolean` ```typescript -import { Value } from "@novu/api/models/components"; +const value: boolean = true; +``` -let value: Value = "OR"; +### `components.Four` + +```typescript +const value: components.Four = {}; ``` -## Values +### `components.Five[]` ```typescript -"AND" | "OR" -``` \ No newline at end of file +const value: components.Five[] = [ + "xx xx xx ", +]; +``` + diff --git a/docs/models/components/weekdays.md b/docs/models/components/weekdays.md index 91b6e4d9..faebcd38 100644 --- a/docs/models/components/weekdays.md +++ b/docs/models/components/weekdays.md @@ -5,7 +5,7 @@ ```typescript import { WeekDays } from "@novu/api/models/components"; -let value: WeekDays = "sunday"; +let value: WeekDays = "wednesday"; ``` ## Values diff --git a/docs/models/components/workfloworiginenum.md b/docs/models/components/workfloworiginenum.md index c5ec714d..f31b9125 100644 --- a/docs/models/components/workfloworiginenum.md +++ b/docs/models/components/workfloworiginenum.md @@ -7,7 +7,7 @@ Origin of the workflow ```typescript import { WorkflowOriginEnum } from "@novu/api/models/components"; -let value: WorkflowOriginEnum = "external"; +let value: WorkflowOriginEnum = "novu-cloud-v1"; ``` ## Values diff --git a/docs/models/components/workflowpreferencedto.md b/docs/models/components/workflowpreferencedto.md deleted file mode 100644 index cd4f6f5c..00000000 --- a/docs/models/components/workflowpreferencedto.md +++ /dev/null @@ -1,32 +0,0 @@ -# WorkflowPreferenceDto - -## Example Usage - -```typescript -import { WorkflowPreferenceDto } from "@novu/api/models/components"; - -let value: WorkflowPreferenceDto = { - enabled: false, - channels: {}, - overrides: [ - { - channel: "push", - source: "workflowOverride", - }, - ], - workflow: { - slug: "", - identifier: "", - name: "", - }, -}; -``` - -## Fields - -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | -| `enabled` | *boolean* | :heavy_check_mark: | Whether notifications are enabled for this workflow | -| `channels` | [components.PreferenceChannels](../../models/components/preferencechannels.md) | :heavy_check_mark: | Channel-specific preference settings for this workflow | -| `overrides` | [components.Overrides](../../models/components/overrides.md)[] | :heavy_check_mark: | List of preference overrides | -| `workflow` | [components.WorkflowInfoDto](../../models/components/workflowinfodto.md) | :heavy_check_mark: | Workflow information | \ No newline at end of file diff --git a/docs/models/components/workflowresponse.md b/docs/models/components/workflowresponse.md index fceee348..f473300f 100644 --- a/docs/models/components/workflowresponse.md +++ b/docs/models/components/workflowresponse.md @@ -7,11 +7,16 @@ import { WorkflowResponse } from "@novu/api/models/components"; let value: WorkflowResponse = { name: "", - description: - "strict unnecessarily hamburger splosh around apologise lest ick", + description: "wearily whether ski usually scarcely frivolous adaptation", active: false, draft: false, - preferenceSettings: {}, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, critical: false, tags: [ "", @@ -42,26 +47,26 @@ let value: WorkflowResponse = { ## Fields -| Field | Type | Required | Description | -| -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------- | -| `id` | *string* | :heavy_minus_sign: | N/A | -| `name` | *string* | :heavy_check_mark: | N/A | -| `description` | *string* | :heavy_check_mark: | N/A | -| `active` | *boolean* | :heavy_check_mark: | N/A | -| `draft` | *boolean* | :heavy_check_mark: | N/A | -| `preferenceSettings` | [components.PreferenceChannels](../../models/components/preferencechannels.md) | :heavy_check_mark: | N/A | -| `critical` | *boolean* | :heavy_check_mark: | N/A | -| `tags` | *string*[] | :heavy_check_mark: | N/A | -| `steps` | [components.NotificationStepDto](../../models/components/notificationstepdto.md)[] | :heavy_check_mark: | N/A | -| `organizationId` | *string* | :heavy_check_mark: | N/A | -| `creatorId` | *string* | :heavy_check_mark: | N/A | -| `environmentId` | *string* | :heavy_check_mark: | N/A | -| `triggers` | [components.NotificationTrigger](../../models/components/notificationtrigger.md)[] | :heavy_check_mark: | N/A | -| `notificationGroupId` | *string* | :heavy_check_mark: | N/A | -| `parentId` | *string* | :heavy_minus_sign: | N/A | -| `deleted` | *boolean* | :heavy_check_mark: | N/A | -| `deletedAt` | *string* | :heavy_check_mark: | N/A | -| `deletedBy` | *string* | :heavy_check_mark: | N/A | -| `notificationGroup` | [components.NotificationGroup](../../models/components/notificationgroup.md) | :heavy_minus_sign: | N/A | -| `data` | [components.WorkflowResponseData](../../models/components/workflowresponsedata.md) | :heavy_minus_sign: | N/A | -| `workflowIntegrationStatus` | [components.WorkflowIntegrationStatus](../../models/components/workflowintegrationstatus.md) | :heavy_minus_sign: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_minus_sign: | N/A | +| `name` | *string* | :heavy_check_mark: | N/A | +| `description` | *string* | :heavy_check_mark: | N/A | +| `active` | *boolean* | :heavy_check_mark: | N/A | +| `draft` | *boolean* | :heavy_check_mark: | N/A | +| `preferenceSettings` | [components.SubscriberPreferenceChannels](../../models/components/subscriberpreferencechannels.md) | :heavy_check_mark: | N/A | +| `critical` | *boolean* | :heavy_check_mark: | N/A | +| `tags` | *string*[] | :heavy_check_mark: | N/A | +| `steps` | [components.NotificationStepDto](../../models/components/notificationstepdto.md)[] | :heavy_check_mark: | N/A | +| `organizationId` | *string* | :heavy_check_mark: | N/A | +| `creatorId` | *string* | :heavy_check_mark: | N/A | +| `environmentId` | *string* | :heavy_check_mark: | N/A | +| `triggers` | [components.NotificationTrigger](../../models/components/notificationtrigger.md)[] | :heavy_check_mark: | N/A | +| `notificationGroupId` | *string* | :heavy_check_mark: | N/A | +| `parentId` | *string* | :heavy_minus_sign: | N/A | +| `deleted` | *boolean* | :heavy_check_mark: | N/A | +| `deletedAt` | *string* | :heavy_check_mark: | N/A | +| `deletedBy` | *string* | :heavy_check_mark: | N/A | +| `notificationGroup` | [components.NotificationGroup](../../models/components/notificationgroup.md) | :heavy_minus_sign: | N/A | +| `data` | [components.WorkflowResponseData](../../models/components/workflowresponsedata.md) | :heavy_minus_sign: | N/A | +| `workflowIntegrationStatus` | [components.WorkflowIntegrationStatus](../../models/components/workflowintegrationstatus.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/errors/errordto.md b/docs/models/errors/errordto.md index 3f788a67..d3339800 100644 --- a/docs/models/errors/errordto.md +++ b/docs/models/errors/errordto.md @@ -15,6 +15,6 @@ import { ErrorDto } from "@novu/api/models/errors"; | `statusCode` | *number* | :heavy_check_mark: | HTTP status code of the error response. | 404 | | `timestamp` | *string* | :heavy_check_mark: | Timestamp of when the error occurred. | 2024-12-12T13:00:00Z | | `path` | *string* | :heavy_check_mark: | The path where the error occurred. | /api/v1/resource | -| `message` | *string* | :heavy_check_mark: | A detailed error message. | Resource not found. | +| `message` | *errors.Message* | :heavy_minus_sign: | Value that failed validation | xx xx xx | | `ctx` | Record | :heavy_minus_sign: | Optional context object for additional error details. | {
"workflowId": "some_wf_id",
"stepId": "some_wf_id"
} | | `errorId` | *string* | :heavy_minus_sign: | Optional unique identifier for the error, useful for tracking using Sentry and
New Relic, only available for 500. | abc123 | \ No newline at end of file diff --git a/docs/models/errors/errors.md b/docs/models/errors/errors.md deleted file mode 100644 index f07fd62f..00000000 --- a/docs/models/errors/errors.md +++ /dev/null @@ -1,22 +0,0 @@ -# Errors - -## Example Usage - -```typescript -import { Errors } from "@novu/api/models/errors"; - -let value: Errors = { - messages: [ - "Field is required", - "Invalid format", - ], - value: "xx xx xx ", -}; -``` - -## Fields - -| Field | Type | Required | Description | -| ------------------ | ------------------ | ------------------ | ------------------ | -| `messages` | *string*[] | :heavy_check_mark: | N/A | -| `value` | *errors.Value* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/errors/five.md b/docs/models/errors/five.md new file mode 100644 index 00000000..ba4c9d4b --- /dev/null +++ b/docs/models/errors/five.md @@ -0,0 +1,31 @@ +# Five + + +## Supported Types + +### `string` + +```typescript +const value: string = ""; +``` + +### `number` + +```typescript +const value: number = 1284.03; +``` + +### `boolean` + +```typescript +const value: boolean = false; +``` + +### `{ [k: string]: any }` + +```typescript +const value: { [k: string]: any } = { + "key": "", +}; +``` + diff --git a/docs/models/errors/four.md b/docs/models/errors/four.md new file mode 100644 index 00000000..d86eb800 --- /dev/null +++ b/docs/models/errors/four.md @@ -0,0 +1,14 @@ +# Four + +## Example Usage + +```typescript +import { Four } from "@novu/api/models/errors"; + +let value: Four = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/errors/message.md b/docs/models/errors/message.md new file mode 100644 index 00000000..651fe159 --- /dev/null +++ b/docs/models/errors/message.md @@ -0,0 +1,39 @@ +# Message + +Value that failed validation + + +## Supported Types + +### `string` + +```typescript +const value: string = "xx xx xx "; +``` + +### `number` + +```typescript +const value: number = xx xx xx ; +``` + +### `boolean` + +```typescript +const value: boolean = true; +``` + +### `errors.Four` + +```typescript +const value: errors.Four = {}; +``` + +### `errors.Five[]` + +```typescript +const value: errors.Five[] = [ + "xx xx xx ", +]; +``` + diff --git a/docs/models/errors/message4.md b/docs/models/errors/message4.md new file mode 100644 index 00000000..a0d9e7d6 --- /dev/null +++ b/docs/models/errors/message4.md @@ -0,0 +1,14 @@ +# Message4 + +## Example Usage + +```typescript +import { Message4 } from "@novu/api/models/errors"; + +let value: Message4 = {}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------- | ----------- | ----------- | ----------- | \ No newline at end of file diff --git a/docs/models/errors/message5.md b/docs/models/errors/message5.md new file mode 100644 index 00000000..b63c1f4a --- /dev/null +++ b/docs/models/errors/message5.md @@ -0,0 +1,31 @@ +# Message5 + + +## Supported Types + +### `string` + +```typescript +const value: string = ""; +``` + +### `number` + +```typescript +const value: number = 1284.03; +``` + +### `boolean` + +```typescript +const value: boolean = false; +``` + +### `{ [k: string]: any }` + +```typescript +const value: { [k: string]: any } = { + "key": "", +}; +``` + diff --git a/docs/models/errors/validationerrordto.md b/docs/models/errors/validationerrordto.md index 2e3d615d..11b3dd95 100644 --- a/docs/models/errors/validationerrordto.md +++ b/docs/models/errors/validationerrordto.md @@ -10,12 +10,12 @@ import { ValidationErrorDto } from "@novu/api/models/errors"; ## Fields -| Field | Type | Required | Description | Example | -| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `statusCode` | *number* | :heavy_check_mark: | HTTP status code of the error response. | 404 | -| `timestamp` | *string* | :heavy_check_mark: | Timestamp of when the error occurred. | 2024-12-12T13:00:00Z | -| `path` | *string* | :heavy_check_mark: | The path where the error occurred. | /api/v1/resource | -| `message` | *string* | :heavy_check_mark: | A detailed error message. | Resource not found. | -| `ctx` | Record | :heavy_minus_sign: | Optional context object for additional error details. | {
"workflowId": "some_wf_id",
"stepId": "some_wf_id"
} | -| `errorId` | *string* | :heavy_minus_sign: | Optional unique identifier for the error, useful for tracking using Sentry and
New Relic, only available for 500. | abc123 | -| `errors` | Record | :heavy_check_mark: | A record of validation errors keyed by field name | {
"fieldName1": {
"messages": [
"Field is required",
"Must be a valid email address"
],
"value": "invalidEmail"
},
"fieldName2": {
"messages": [
"Must be at least 18 years old"
],
"value": 17
},
"fieldName3": {
"messages": [
"Must be a boolean value"
],
"value": true
},
"fieldName4": {
"messages": [
"Must be a valid object"
],
"value": {
"key": "value"
}
}
} | \ No newline at end of file +| Field | Type | Required | Description | Example | +| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `statusCode` | *number* | :heavy_check_mark: | HTTP status code of the error response. | 404 | +| `timestamp` | *string* | :heavy_check_mark: | Timestamp of when the error occurred. | 2024-12-12T13:00:00Z | +| `path` | *string* | :heavy_check_mark: | The path where the error occurred. | /api/v1/resource | +| `message` | *errors.ValidationErrorDtoMessage* | :heavy_minus_sign: | Value that failed validation | xx xx xx | +| `ctx` | Record | :heavy_minus_sign: | Optional context object for additional error details. | {
"workflowId": "some_wf_id",
"stepId": "some_wf_id"
} | +| `errorId` | *string* | :heavy_minus_sign: | Optional unique identifier for the error, useful for tracking using Sentry and
New Relic, only available for 500. | abc123 | +| `errors` | Record | :heavy_check_mark: | A record of validation errors keyed by field name | {
"fieldName1": {
"messages": [
"Field is required",
"Must be a valid email address"
],
"value": "invalidEmail"
},
"fieldName2": {
"messages": [
"Must be at least 18 years old"
],
"value": 17
},
"fieldName3": {
"messages": [
"Must be a boolean value"
],
"value": true
},
"fieldName4": {
"messages": [
"Must be a valid object"
],
"value": {
"key": "value"
}
},
"fieldName5": {
"messages": [
"Field is missing"
],
"value": null
},
"fieldName6": {
"messages": [
"Undefined value"
]
}
} | \ No newline at end of file diff --git a/docs/models/errors/validationerrordtomessage.md b/docs/models/errors/validationerrordtomessage.md new file mode 100644 index 00000000..c4c3c8c1 --- /dev/null +++ b/docs/models/errors/validationerrordtomessage.md @@ -0,0 +1,39 @@ +# ValidationErrorDtoMessage + +Value that failed validation + + +## Supported Types + +### `string` + +```typescript +const value: string = "xx xx xx "; +``` + +### `number` + +```typescript +const value: number = xx xx xx ; +``` + +### `boolean` + +```typescript +const value: boolean = true; +``` + +### `errors.Message4` + +```typescript +const value: errors.Message4 = {}; +``` + +### `errors.Message5[]` + +```typescript +const value: errors.Message5[] = [ + "xx xx xx ", +]; +``` + diff --git a/docs/models/operations/eventscontrollerbroadcasteventtoallrequest.md b/docs/models/operations/eventscontrollerbroadcasteventtoallrequest.md index 41283a4f..66d9676a 100644 --- a/docs/models/operations/eventscontrollerbroadcasteventtoallrequest.md +++ b/docs/models/operations/eventscontrollerbroadcasteventtoallrequest.md @@ -14,7 +14,15 @@ let value: EventsControllerBroadcastEventToAllRequest = { "text": "string", }, }, - overrides: {}, + overrides: { + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }, }; ``` diff --git a/docs/models/operations/eventscontrollertriggerbulkrequest.md b/docs/models/operations/eventscontrollertriggerbulkrequest.md index f0ba6772..1afc793e 100644 --- a/docs/models/operations/eventscontrollertriggerbulkrequest.md +++ b/docs/models/operations/eventscontrollertriggerbulkrequest.md @@ -16,16 +16,13 @@ let value: EventsControllerTriggerBulkRequest = { "text": "string", }, }, - overrides: { - "fcm": { - "data": { - "key": "value", - }, + overrides: {}, + to: [ + { + topicKey: "", + type: "Subscriber", }, - }, - to: { - subscriberId: "", - }, + ], }, ], }, diff --git a/docs/models/operations/eventscontrollertriggerbulkresponse.md b/docs/models/operations/eventscontrollertriggerbulkresponse.md index 37ad9c7a..68144a1a 100644 --- a/docs/models/operations/eventscontrollertriggerbulkresponse.md +++ b/docs/models/operations/eventscontrollertriggerbulkresponse.md @@ -14,7 +14,7 @@ let value: EventsControllerTriggerBulkResponse = { result: [ { acknowledged: false, - status: "no_workflow_active_steps_defined", + status: "error", }, ], }; diff --git a/docs/models/operations/eventscontrollertriggerrequest.md b/docs/models/operations/eventscontrollertriggerrequest.md index d02d3e20..ba5e5859 100644 --- a/docs/models/operations/eventscontrollertriggerrequest.md +++ b/docs/models/operations/eventscontrollertriggerrequest.md @@ -14,13 +14,7 @@ let value: EventsControllerTriggerRequest = { "text": "string", }, }, - overrides: { - "fcm": { - "data": { - "key": "value", - }, - }, - }, + overrides: {}, to: { subscriberId: "", }, diff --git a/docs/models/operations/eventscontrollertriggerresponse.md b/docs/models/operations/eventscontrollertriggerresponse.md index 49daaea5..b3ea7722 100644 --- a/docs/models/operations/eventscontrollertriggerresponse.md +++ b/docs/models/operations/eventscontrollertriggerresponse.md @@ -13,7 +13,7 @@ let value: EventsControllerTriggerResponse = { }, result: { acknowledged: false, - status: "no_tenant_found", + status: "trigger_not_active", }, }; ``` diff --git a/docs/models/operations/integrationscontrollercreateintegrationresponse.md b/docs/models/operations/integrationscontrollercreateintegrationresponse.md index 9555804e..5a3caf52 100644 --- a/docs/models/operations/integrationscontrollercreateintegrationresponse.md +++ b/docs/models/operations/integrationscontrollercreateintegrationresponse.md @@ -17,7 +17,7 @@ let value: IntegrationsControllerCreateIntegrationResponse = { name: "", identifier: "", providerId: "", - channel: "chat", + channel: "push", credentials: {}, active: false, deleted: false, diff --git a/docs/models/operations/integrationscontrollerlistintegrationsresponse.md b/docs/models/operations/integrationscontrollerlistintegrationsresponse.md index 69a25768..9d265931 100644 --- a/docs/models/operations/integrationscontrollerlistintegrationsresponse.md +++ b/docs/models/operations/integrationscontrollerlistintegrationsresponse.md @@ -18,7 +18,7 @@ let value: IntegrationsControllerListIntegrationsResponse = { name: "", identifier: "", providerId: "", - channel: "sms", + channel: "push", credentials: {}, active: false, deleted: false, diff --git a/docs/models/operations/integrationscontrollerremoveintegrationresponse.md b/docs/models/operations/integrationscontrollerremoveintegrationresponse.md index 263516cb..03ddc9b5 100644 --- a/docs/models/operations/integrationscontrollerremoveintegrationresponse.md +++ b/docs/models/operations/integrationscontrollerremoveintegrationresponse.md @@ -18,7 +18,7 @@ let value: IntegrationsControllerRemoveIntegrationResponse = { name: "", identifier: "", providerId: "", - channel: "in_app", + channel: "sms", credentials: {}, active: false, deleted: false, diff --git a/docs/models/operations/integrationscontrollersetintegrationasprimaryresponse.md b/docs/models/operations/integrationscontrollersetintegrationasprimaryresponse.md index 1edf0bb4..79c83b46 100644 --- a/docs/models/operations/integrationscontrollersetintegrationasprimaryresponse.md +++ b/docs/models/operations/integrationscontrollersetintegrationasprimaryresponse.md @@ -17,7 +17,7 @@ let value: IntegrationsControllerSetIntegrationAsPrimaryResponse = { name: "", identifier: "", providerId: "", - channel: "email", + channel: "chat", credentials: {}, active: false, deleted: false, diff --git a/docs/models/operations/integrationscontrollerupdateintegrationbyidresponse.md b/docs/models/operations/integrationscontrollerupdateintegrationbyidresponse.md index 9eb47be9..990b31ef 100644 --- a/docs/models/operations/integrationscontrollerupdateintegrationbyidresponse.md +++ b/docs/models/operations/integrationscontrollerupdateintegrationbyidresponse.md @@ -17,7 +17,7 @@ let value: IntegrationsControllerUpdateIntegrationByIdResponse = { name: "", identifier: "", providerId: "", - channel: "chat", + channel: "in_app", credentials: {}, active: false, deleted: false, diff --git a/docs/models/operations/messagescontrollergetmessagesresponse.md b/docs/models/operations/messagescontrollergetmessagesresponse.md index 81a4e0e7..bf554a43 100644 --- a/docs/models/operations/messagescontrollergetmessagesresponse.md +++ b/docs/models/operations/messagescontrollergetmessagesresponse.md @@ -13,16 +13,104 @@ let value: MessagesControllerGetMessagesResponse = { }, result: { hasMore: false, - data: [], - pageSize: 2961.4, - page: 1187.27, + data: [ + { + templateId: "", + environmentId: "", + messageTemplateId: "", + organizationId: "", + notificationId: "", + subscriberId: "", + subscriber: { + channels: [ + { + providerId: "pushpad", + credentials: { + webhookUrl: "https://example.com/webhook", + channel: "general", + deviceTokens: [ + "token1", + "token2", + "token3", + ], + alertUid: "12345-abcde", + title: "Critical Alert", + imageUrl: "https://example.com/image.png", + state: "resolved", + externalUrl: "https://example.com/details", + }, + integrationId: "", + }, + ], + subscriberId: "", + organizationId: "", + environmentId: "", + deleted: false, + createdAt: "1746288353859", + updatedAt: "1746655560490", + }, + template: { + name: "", + description: "instead digital entwine cheese", + active: false, + draft: false, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + critical: false, + tags: [ + "", + ], + steps: [ + {}, + ], + organizationId: "", + creatorId: "", + environmentId: "", + triggers: [ + { + type: "event", + identifier: "", + variables: [ + { + name: "", + }, + ], + }, + ], + notificationGroupId: "", + deleted: false, + deletedAt: "", + deletedBy: "", + }, + createdAt: "1716308911811", + content: [ + { + type: "button", + content: "", + }, + ], + transactionId: "", + channel: "chat", + read: false, + seen: false, + cta: {}, + status: "sent", + }, + ], + pageSize: 5045.67, + page: 1342.74, }, }; ``` ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | -| `headers` | Record | :heavy_check_mark: | N/A | -| `result` | [components.ActivitiesResponseDto](../../models/components/activitiesresponsedto.md) | :heavy_check_mark: | N/A | \ No newline at end of file +| Field | Type | Required | Description | +| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | +| `headers` | Record | :heavy_check_mark: | N/A | +| `result` | [components.MessagesResponseDto](../../models/components/messagesresponsedto.md) | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/operations/notificationscontrollergetactivitygraphstatsresponse.md b/docs/models/operations/notificationscontrollergetactivitygraphstatsresponse.md index 62d283be..d08123e8 100644 --- a/docs/models/operations/notificationscontrollergetactivitygraphstatsresponse.md +++ b/docs/models/operations/notificationscontrollergetactivitygraphstatsresponse.md @@ -14,12 +14,12 @@ let value: NotificationsControllerGetActivityGraphStatsResponse = { result: [ { id: "", - count: 6924.72, + count: 4178.18, templates: [ "", ], channels: [ - "sms", + "push", ], }, ], diff --git a/docs/models/operations/notificationscontrollergetactivitystatsresponse.md b/docs/models/operations/notificationscontrollergetactivitystatsresponse.md index 4e34fda8..02ca8c93 100644 --- a/docs/models/operations/notificationscontrollergetactivitystatsresponse.md +++ b/docs/models/operations/notificationscontrollergetactivitystatsresponse.md @@ -12,8 +12,8 @@ let value: NotificationsControllerGetActivityStatsResponse = { ], }, result: { - weeklySent: 2653.89, - monthlySent: 5232.48, + weeklySent: 179.28, + monthlySent: 854.46, }, }; ``` diff --git a/docs/models/operations/notificationscontrollergetnotificationresponse.md b/docs/models/operations/notificationscontrollergetnotificationresponse.md index db32e107..20538e2e 100644 --- a/docs/models/operations/notificationscontrollergetnotificationresponse.md +++ b/docs/models/operations/notificationscontrollergetnotificationresponse.md @@ -16,7 +16,49 @@ let value: NotificationsControllerGetNotificationResponse = { organizationId: "", subscriberId: "", transactionId: "", - jobs: [], + jobs: [ + { + id: "", + type: "delay", + executionDetails: [ + { + id: "", + status: "Warning", + detail: "", + isRetry: false, + isTest: false, + providerId: "firetext", + source: "Internal", + }, + ], + step: { + id: "", + active: false, + filters: [ + { + isNegated: false, + type: "BOOLEAN", + value: "OR", + children: [ + { + field: "", + value: "", + operator: "LARGER", + on: "payload", + }, + ], + }, + ], + templateId: "", + }, + overrides: { + "workflowId": "some_wf_id", + "stepId": "some_wf_id", + }, + providerId: "sms-central", + status: "", + }, + ], }, }; ``` diff --git a/docs/models/operations/notificationscontrollerlistnotificationsresponse.md b/docs/models/operations/notificationscontrollerlistnotificationsresponse.md index e03cddbe..58925f3d 100644 --- a/docs/models/operations/notificationscontrollerlistnotificationsresponse.md +++ b/docs/models/operations/notificationscontrollerlistnotificationsresponse.md @@ -13,9 +13,59 @@ let value: NotificationsControllerListNotificationsResponse = { }, result: { hasMore: false, - data: [], - pageSize: 4142.63, - page: 641.47, + data: [ + { + environmentId: "", + organizationId: "", + subscriberId: "", + transactionId: "", + jobs: [ + { + id: "", + type: "digest", + executionDetails: [ + { + id: "", + status: "ReadConfirmation", + detail: "", + isRetry: false, + isTest: false, + providerId: "discord", + source: "Internal", + }, + ], + step: { + id: "", + active: false, + filters: [ + { + isNegated: false, + type: "NUMBER", + value: "OR", + children: [ + { + field: "", + value: "", + operator: "LARGER_EQUAL", + on: "subscriber", + }, + ], + }, + ], + templateId: "", + }, + overrides: { + "workflowId": "some_wf_id", + "stepId": "some_wf_id", + }, + providerId: "mailtrap", + status: "", + }, + ], + }, + ], + pageSize: 1045.5, + page: 6064.82, }, }; ``` diff --git a/docs/models/operations/orderdirection.md b/docs/models/operations/orderdirection.md index 60930dc9..d40ad54a 100644 --- a/docs/models/operations/orderdirection.md +++ b/docs/models/operations/orderdirection.md @@ -7,7 +7,7 @@ Direction of sorting ```typescript import { OrderDirection } from "@novu/api/models/operations"; -let value: OrderDirection = "DESC"; +let value: OrderDirection = "ASC"; ``` ## Values diff --git a/docs/models/operations/subscriberscontrollercreatesubscriberresponse.md b/docs/models/operations/subscriberscontrollercreatesubscriberresponse.md index eee08a82..7d86f677 100644 --- a/docs/models/operations/subscriberscontrollercreatesubscriberresponse.md +++ b/docs/models/operations/subscriberscontrollercreatesubscriberresponse.md @@ -12,10 +12,9 @@ let value: SubscribersControllerCreateSubscriberResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "grafana-on-call", + providerId: "discord", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersControllerCreateSubscriberResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1736871205870", - updatedAt: "1743398661852", + createdAt: "1744852600437", + updatedAt: "1746636911308", }, }; ``` diff --git a/docs/models/operations/subscriberscontrollergetsubscriberpreferencesresponse.md b/docs/models/operations/subscriberscontrollergetsubscriberpreferencesresponse.md index 4e7e59b6..f217080e 100644 --- a/docs/models/operations/subscriberscontrollergetsubscriberpreferencesresponse.md +++ b/docs/models/operations/subscriberscontrollergetsubscriberpreferencesresponse.md @@ -14,16 +14,28 @@ let value: SubscribersControllerGetSubscriberPreferencesResponse = { result: { global: { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, }, workflows: [ { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, overrides: [ { - channel: "chat", - source: "template", + channel: "in_app", + source: "workflowOverride", }, ], workflow: { diff --git a/docs/models/operations/subscriberscontrollergetsubscriberresponse.md b/docs/models/operations/subscriberscontrollergetsubscriberresponse.md index eb08ed4d..a9467018 100644 --- a/docs/models/operations/subscriberscontrollergetsubscriberresponse.md +++ b/docs/models/operations/subscriberscontrollergetsubscriberresponse.md @@ -12,10 +12,9 @@ let value: SubscribersControllerGetSubscriberResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "whatsapp-business", + providerId: "apns", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersControllerGetSubscriberResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1741092980528", - updatedAt: "1743359103312", + createdAt: "1718337153326", + updatedAt: "1746631936837", }, }; ``` diff --git a/docs/models/operations/subscriberscontrollerpatchsubscriberresponse.md b/docs/models/operations/subscriberscontrollerpatchsubscriberresponse.md index 8630de69..e013f670 100644 --- a/docs/models/operations/subscriberscontrollerpatchsubscriberresponse.md +++ b/docs/models/operations/subscriberscontrollerpatchsubscriberresponse.md @@ -12,10 +12,9 @@ let value: SubscribersControllerPatchSubscriberResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "discord", + providerId: "ryver", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersControllerPatchSubscriberResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1712540973238", - updatedAt: "1743424903400", + createdAt: "1726910723093", + updatedAt: "1746642418155", }, }; ``` diff --git a/docs/models/operations/subscriberscontrollersearchsubscribersresponse.md b/docs/models/operations/subscriberscontrollersearchsubscribersresponse.md index 76a4adde..c77c294a 100644 --- a/docs/models/operations/subscriberscontrollersearchsubscribersresponse.md +++ b/docs/models/operations/subscriberscontrollersearchsubscribersresponse.md @@ -14,10 +14,9 @@ let value: SubscribersControllerSearchSubscribersResponse = { result: { data: [ { - subscriberId: "", channels: [ { - providerId: "getstream", + providerId: "slack", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -35,11 +34,12 @@ let value: SubscribersControllerSearchSubscribersResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1740026318311", - updatedAt: "1743436225349", + createdAt: "1734343132968", + updatedAt: "1746599465536", }, ], next: "", diff --git a/docs/models/operations/subscriberscontrollerupdatesubscriberpreferencesresponse.md b/docs/models/operations/subscriberscontrollerupdatesubscriberpreferencesresponse.md index e0aa4ead..ee62bf13 100644 --- a/docs/models/operations/subscriberscontrollerupdatesubscriberpreferencesresponse.md +++ b/docs/models/operations/subscriberscontrollerupdatesubscriberpreferencesresponse.md @@ -14,16 +14,28 @@ let value: SubscribersControllerUpdateSubscriberPreferencesResponse = { result: { global: { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, }, workflows: [ { enabled: false, - channels: {}, + channels: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, overrides: [ { - channel: "sms", - source: "subscriber", + channel: "push", + source: "workflowOverride", }, ], workflow: { diff --git a/docs/models/operations/subscribersv1controllergetnotificationsfeedresponse.md b/docs/models/operations/subscribersv1controllergetnotificationsfeedresponse.md index 72fd3b5c..b1362785 100644 --- a/docs/models/operations/subscribersv1controllergetnotificationsfeedresponse.md +++ b/docs/models/operations/subscribersv1controllergetnotificationsfeedresponse.md @@ -39,14 +39,11 @@ let value: SubscribersV1ControllerGetNotificationsFeedResponse = { channel: "push", read: false, seen: true, - deleted: false, deviceTokens: [ "token1", "token2", ], - cta: { - data: {}, - }, + cta: {}, status: "sent", payload: { "key": "value", diff --git a/docs/models/operations/subscribersv1controllergetunseencountresponse.md b/docs/models/operations/subscribersv1controllergetunseencountresponse.md index 600ac5e8..1d9e44b4 100644 --- a/docs/models/operations/subscribersv1controllergetunseencountresponse.md +++ b/docs/models/operations/subscribersv1controllergetunseencountresponse.md @@ -12,7 +12,7 @@ let value: SubscribersV1ControllerGetUnseenCountResponse = { ], }, result: { - count: 971.01, + count: 8137.14, }, }; ``` diff --git a/docs/models/operations/subscribersv1controllerlistsubscribersresponse.md b/docs/models/operations/subscribersv1controllerlistsubscribersresponse.md index 8bf5a7a9..fb0f2412 100644 --- a/docs/models/operations/subscribersv1controllerlistsubscribersresponse.md +++ b/docs/models/operations/subscribersv1controllerlistsubscribersresponse.md @@ -12,15 +12,14 @@ let value: SubscribersV1ControllerListSubscribersResponse = { ], }, result: { - page: 7805.29, + page: 7951.88, hasMore: false, - pageSize: 1182.74, + pageSize: 5096.25, data: [ { - subscriberId: "", channels: [ { - providerId: "fcm", + providerId: "expo", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -38,11 +37,12 @@ let value: SubscribersV1ControllerListSubscribersResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1716424155028", - updatedAt: "1743434584350", + createdAt: "1718189186066", + updatedAt: "1746637194967", }, ], }, diff --git a/docs/models/operations/subscribersv1controllerlistsubscribersresponsebody.md b/docs/models/operations/subscribersv1controllerlistsubscribersresponsebody.md index d8fb9d6a..a81ac31f 100644 --- a/docs/models/operations/subscribersv1controllerlistsubscribersresponsebody.md +++ b/docs/models/operations/subscribersv1controllerlistsubscribersresponsebody.md @@ -6,15 +6,14 @@ import { SubscribersV1ControllerListSubscribersResponseBody } from "@novu/api/models/operations"; let value: SubscribersV1ControllerListSubscribersResponseBody = { - page: 7781.57, + page: 9399.74, hasMore: false, - pageSize: 8700.13, + pageSize: 3588.74, data: [ { - subscriberId: "", channels: [ { - providerId: "pusher-beams", + providerId: "fcm", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -32,11 +31,12 @@ let value: SubscribersV1ControllerListSubscribersResponseBody = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1737105629575", - updatedAt: "1743392837248", + createdAt: "1732754830927", + updatedAt: "1746611310155", }, ], }; diff --git a/docs/models/operations/subscribersv1controllermarkactionasseenresponse.md b/docs/models/operations/subscribersv1controllermarkactionasseenresponse.md index 6a4f81c8..73494cd7 100644 --- a/docs/models/operations/subscribersv1controllermarkactionasseenresponse.md +++ b/docs/models/operations/subscribersv1controllermarkactionasseenresponse.md @@ -19,10 +19,9 @@ let value: SubscribersV1ControllerMarkActionAsSeenResponse = { notificationId: "", subscriberId: "", subscriber: { - subscriberId: "", channels: [ { - providerId: "apns", + providerId: "slack", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -40,24 +39,63 @@ let value: SubscribersV1ControllerMarkActionAsSeenResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1718537990265", - updatedAt: "1743364105133", + createdAt: "1736175762345", + updatedAt: "1746579736668", }, - createdAt: "1721850714192", - content: { - type: "text", - content: "", + template: { + name: "", + description: "whose steak scented ribbon only um", + active: false, + draft: false, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + critical: false, + tags: [ + "", + ], + steps: [ + {}, + ], + organizationId: "", + creatorId: "", + environmentId: "", + triggers: [ + { + type: "event", + identifier: "", + variables: [ + { + name: "", + }, + ], + }, + ], + notificationGroupId: "", + deleted: false, + deletedAt: "", + deletedBy: "", }, + createdAt: "1732176644377", + content: [ + { + type: "text", + content: "", + }, + ], transactionId: "", - channel: "sms", + channel: "email", read: false, seen: false, - cta: { - data: {}, - }, + cta: {}, status: "warning", }, }; diff --git a/docs/models/operations/subscribersv1controllermarkallunreadasreadrequest.md b/docs/models/operations/subscribersv1controllermarkallunreadasreadrequest.md index 4ec19b92..af244f03 100644 --- a/docs/models/operations/subscribersv1controllermarkallunreadasreadrequest.md +++ b/docs/models/operations/subscribersv1controllermarkallunreadasreadrequest.md @@ -8,7 +8,7 @@ import { SubscribersV1ControllerMarkAllUnreadAsReadRequest } from "@novu/api/mod let value: SubscribersV1ControllerMarkAllUnreadAsReadRequest = { subscriberId: "", markAllMessageAsRequestDto: { - markAs: "read", + markAs: "seen", }, }; ``` diff --git a/docs/models/operations/subscribersv1controllermarkallunreadasreadresponse.md b/docs/models/operations/subscribersv1controllermarkallunreadasreadresponse.md index 93c0de60..88b908c8 100644 --- a/docs/models/operations/subscribersv1controllermarkallunreadasreadresponse.md +++ b/docs/models/operations/subscribersv1controllermarkallunreadasreadresponse.md @@ -11,7 +11,7 @@ let value: SubscribersV1ControllerMarkAllUnreadAsReadResponse = { "", ], }, - result: 2088.76, + result: 4515.31, }; ``` diff --git a/docs/models/operations/subscribersv1controllermarkmessagesasrequest.md b/docs/models/operations/subscribersv1controllermarkmessagesasrequest.md index c29f3fb1..3aba8a67 100644 --- a/docs/models/operations/subscribersv1controllermarkmessagesasrequest.md +++ b/docs/models/operations/subscribersv1controllermarkmessagesasrequest.md @@ -8,8 +8,10 @@ import { SubscribersV1ControllerMarkMessagesAsRequest } from "@novu/api/models/o let value: SubscribersV1ControllerMarkMessagesAsRequest = { subscriberId: "", messageMarkAsRequestDto: { - messageId: "", - markAs: "unread", + messageId: [ + "", + ], + markAs: "read", }, }; ``` diff --git a/docs/models/operations/subscribersv1controllermarkmessagesasresponse.md b/docs/models/operations/subscribersv1controllermarkmessagesasresponse.md index f75d803c..dea1a69d 100644 --- a/docs/models/operations/subscribersv1controllermarkmessagesasresponse.md +++ b/docs/models/operations/subscribersv1controllermarkmessagesasresponse.md @@ -20,10 +20,9 @@ let value: SubscribersV1ControllerMarkMessagesAsResponse = { notificationId: "", subscriberId: "", subscriber: { - subscriberId: "", channels: [ { - providerId: "ryver", + providerId: "pushpad", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -41,25 +40,59 @@ let value: SubscribersV1ControllerMarkMessagesAsResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1726608942144", - updatedAt: "1743374084204", + createdAt: "1744560535372", + updatedAt: "1746595547140", }, - createdAt: "1716916630710", - content: { - type: "text", - content: "", + template: { + name: "", + description: "weary goodwill until skean yahoo preclude", + active: false, + draft: false, + preferenceSettings: { + email: true, + sms: false, + inApp: true, + chat: false, + push: true, + }, + critical: false, + tags: [ + "", + ], + steps: [ + {}, + ], + organizationId: "", + creatorId: "", + environmentId: "", + triggers: [ + { + type: "event", + identifier: "", + variables: [ + { + name: "", + }, + ], + }, + ], + notificationGroupId: "", + deleted: false, + deletedAt: "", + deletedBy: "", }, + createdAt: "1736481441867", + content: "", transactionId: "", channel: "in_app", read: false, seen: false, - cta: { - data: {}, - }, - status: "sent", + cta: {}, + status: "error", }, ], }; diff --git a/docs/models/operations/subscribersv1controllermodifysubscriberchannelrequest.md b/docs/models/operations/subscribersv1controllermodifysubscriberchannelrequest.md index e3589b0d..1f3afdb3 100644 --- a/docs/models/operations/subscribersv1controllermodifysubscriberchannelrequest.md +++ b/docs/models/operations/subscribersv1controllermodifysubscriberchannelrequest.md @@ -8,7 +8,7 @@ import { SubscribersV1ControllerModifySubscriberChannelRequest } from "@novu/api let value: SubscribersV1ControllerModifySubscriberChannelRequest = { subscriberId: "", updateSubscriberChannelRequestDto: { - providerId: "apns", + providerId: "pushpad", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", diff --git a/docs/models/operations/subscribersv1controllermodifysubscriberchannelresponse.md b/docs/models/operations/subscribersv1controllermodifysubscriberchannelresponse.md index 9c5a040c..dc13592d 100644 --- a/docs/models/operations/subscribersv1controllermodifysubscriberchannelresponse.md +++ b/docs/models/operations/subscribersv1controllermodifysubscriberchannelresponse.md @@ -12,10 +12,9 @@ let value: SubscribersV1ControllerModifySubscriberChannelResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "grafana-on-call", + providerId: "msteams", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersV1ControllerModifySubscriberChannelResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1725685605214", - updatedAt: "1743413240594", + createdAt: "1736531336161", + updatedAt: "1746658829206", }, }; ``` diff --git a/docs/models/operations/subscribersv1controllerupdatesubscriberchannelrequest.md b/docs/models/operations/subscribersv1controllerupdatesubscriberchannelrequest.md index a1879b44..7402968b 100644 --- a/docs/models/operations/subscribersv1controllerupdatesubscriberchannelrequest.md +++ b/docs/models/operations/subscribersv1controllerupdatesubscriberchannelrequest.md @@ -8,7 +8,7 @@ import { SubscribersV1ControllerUpdateSubscriberChannelRequest } from "@novu/api let value: SubscribersV1ControllerUpdateSubscriberChannelRequest = { subscriberId: "", updateSubscriberChannelRequestDto: { - providerId: "fcm", + providerId: "pusher-beams", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", diff --git a/docs/models/operations/subscribersv1controllerupdatesubscriberchannelresponse.md b/docs/models/operations/subscribersv1controllerupdatesubscriberchannelresponse.md index ef70aecd..3ef9bee4 100644 --- a/docs/models/operations/subscribersv1controllerupdatesubscriberchannelresponse.md +++ b/docs/models/operations/subscribersv1controllerupdatesubscriberchannelresponse.md @@ -12,10 +12,9 @@ let value: SubscribersV1ControllerUpdateSubscriberChannelResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "fcm", + providerId: "zulip", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersV1ControllerUpdateSubscriberChannelResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1731358995854", - updatedAt: "1743434504836", + createdAt: "1719801044804", + updatedAt: "1746631184819", }, }; ``` diff --git a/docs/models/operations/subscribersv1controllerupdatesubscriberonlineflagresponse.md b/docs/models/operations/subscribersv1controllerupdatesubscriberonlineflagresponse.md index 7398aa1b..27dc8283 100644 --- a/docs/models/operations/subscribersv1controllerupdatesubscriberonlineflagresponse.md +++ b/docs/models/operations/subscribersv1controllerupdatesubscriberonlineflagresponse.md @@ -12,10 +12,9 @@ let value: SubscribersV1ControllerUpdateSubscriberOnlineFlagResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "pushpad", + providerId: "expo", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersV1ControllerUpdateSubscriberOnlineFlagResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1714933925405", - updatedAt: "1743437331232", + createdAt: "1734751955823", + updatedAt: "1746610474290", }, }; ``` diff --git a/docs/models/operations/subscribersv1controllerupdatesubscriberresponse.md b/docs/models/operations/subscribersv1controllerupdatesubscriberresponse.md index 14263d8c..2dc2c355 100644 --- a/docs/models/operations/subscribersv1controllerupdatesubscriberresponse.md +++ b/docs/models/operations/subscribersv1controllerupdatesubscriberresponse.md @@ -12,10 +12,9 @@ let value: SubscribersV1ControllerUpdateSubscriberResponse = { ], }, result: { - subscriberId: "", channels: [ { - providerId: "rocket-chat", + providerId: "zulip", credentials: { webhookUrl: "https://example.com/webhook", channel: "general", @@ -33,11 +32,12 @@ let value: SubscribersV1ControllerUpdateSubscriberResponse = { integrationId: "", }, ], + subscriberId: "", organizationId: "", environmentId: "", deleted: false, - createdAt: "1724980144436", - updatedAt: "1743375823251", + createdAt: "1740958291172", + updatedAt: "1746635825262", }, }; ``` diff --git a/docs/sdks/novu/README.md b/docs/sdks/novu/README.md index 571e6bf5..3fb5cf79 100644 --- a/docs/sdks/novu/README.md +++ b/docs/sdks/novu/README.md @@ -41,9 +41,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -83,9 +92,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -234,6 +252,29 @@ async function run() { "text": "string", }, }, + overrides: { + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }); // Handle the result @@ -266,6 +307,29 @@ async function run() { "text": "string", }, }, + overrides: { + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + additionalProperties: { + "fcm": { + "data": { + "key": "value", + }, + }, + }, + }, }); if (!res.ok) { @@ -333,9 +397,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -352,9 +425,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -374,9 +456,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -421,9 +512,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -440,9 +540,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, @@ -462,9 +571,18 @@ async function run() { }, }, overrides: { - "fcm": { - "data": { - "key": "value", + steps: { + "email-step": { + providers: { + "sendgrid": { + "templateId": "1234567890", + }, + }, + }, + }, + providers: { + "sendgrid": { + "templateId": "1234567890", }, }, }, diff --git a/eslint.config.mjs b/eslint.config.mjs index 3483f71b..67bccfec 100644 --- a/eslint.config.mjs +++ b/eslint.config.mjs @@ -11,6 +11,7 @@ export default [ { rules: { "no-constant-condition": "off", + "no-useless-escape": "off", // Handled by typescript compiler "@typescript-eslint/no-unused-vars": "off", "@typescript-eslint/no-explicit-any": "off", diff --git a/jsr.json b/jsr.json index eb024ebd..005d794c 100644 --- a/jsr.json +++ b/jsr.json @@ -2,7 +2,7 @@ { "name": "@novu/api", - "version": "0.6.2", + "version": "0.7.0", "exports": { ".": "./src/index.ts", "./models/errors": "./src/models/errors/index.ts", diff --git a/package-lock.json b/package-lock.json index d4343090..8e868649 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,18 +1,18 @@ { "name": "@novu/api", - "version": "0.6.2", + "version": "0.7.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@novu/api", - "version": "0.6.2", + "version": "0.7.0", "bin": { "mcp": "bin/mcp-server.js" }, "devDependencies": { "@eslint/js": "^9.19.0", - "@modelcontextprotocol/sdk": "^1.5.0", + "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0", "@stricli/core": "^1.1.1", "@types/express": "^4.17.21", "bun": "^1.2.2", @@ -25,7 +25,7 @@ "zod": "^3.23.4" }, "peerDependencies": { - "@modelcontextprotocol/sdk": "^1.5.0", + "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0", "zod": ">= 3" }, "peerDependenciesMeta": { diff --git a/package.json b/package.json index c196112f..93576e9b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@novu/api", - "version": "0.6.2", + "version": "0.7.0", "author": "Novu", "description": "The infrastructure for modern products", "bin": { @@ -19,7 +19,7 @@ "prepublishOnly": "npm run build" }, "peerDependencies": { - "@modelcontextprotocol/sdk": "^1.5.0", + "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0", "zod": ">= 3" }, "peerDependenciesMeta": { @@ -27,7 +27,7 @@ }, "devDependencies": { "@eslint/js": "^9.19.0", - "@modelcontextprotocol/sdk": "^1.5.0", + "@modelcontextprotocol/sdk": ">=1.5.0 <1.10.0", "@stricli/core": "^1.1.1", "@types/express": "^4.17.21", "bun": "^1.2.2", diff --git a/sources/code-samples.yaml b/sources/code-samples.yaml index f0099afc..8204c37a 100644 --- a/sources/code-samples.yaml +++ b/sources/code-samples.yaml @@ -8,19 +8,19 @@ actions: "x-codeSamples": - "lang": "typescript" "label": "TypeScript" - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.trigger({\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n \"fcm\": {\n \"data\": {\n \"key\": \"value\",\n },\n },\n },\n to: {\n subscriberId: \"\",\n },\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" + "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.trigger({\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n steps: {\n \"email-step\": {\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n },\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n to: {\n subscriberId: \"\",\n },\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" - target: $["paths"]["/v1/events/trigger/broadcast"]["post"] update: "x-codeSamples": - "lang": "typescript" "label": "TypeScript" - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.triggerBroadcast({\n name: \"\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" + "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.triggerBroadcast({\n name: \"\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n steps: {\n \"email-step\": {\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n },\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n additionalProperties: {\n \"fcm\": {\n \"data\": {\n \"key\": \"value\",\n },\n },\n },\n },\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" - target: $["paths"]["/v1/events/trigger/bulk"]["post"] update: "x-codeSamples": - "lang": "typescript" "label": "TypeScript" - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.triggerBulk({\n events: [\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n \"fcm\": {\n \"data\": {\n \"key\": \"value\",\n },\n },\n },\n to: {\n subscriberId: \"\",\n },\n },\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n \"fcm\": {\n \"data\": {\n \"key\": \"value\",\n },\n },\n },\n to: [\n {\n topicKey: \"\",\n type: \"Subscriber\",\n },\n ],\n },\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n \"fcm\": {\n \"data\": {\n \"key\": \"value\",\n },\n },\n },\n to: [\n \"SUBSCRIBER_ID\",\n \"SUBSCRIBER_ID\",\n ],\n },\n ],\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" + "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n secretKey: \"YOUR_SECRET_KEY_HERE\",\n});\n\nasync function run() {\n const result = await novu.triggerBulk({\n events: [\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n steps: {\n \"email-step\": {\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n },\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n to: {\n subscriberId: \"\",\n },\n },\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n steps: {\n \"email-step\": {\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n },\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n to: [\n {\n topicKey: \"\",\n type: \"Subscriber\",\n },\n ],\n },\n {\n workflowId: \"workflow_identifier\",\n payload: {\n \"comment_id\": \"string\",\n \"post\": {\n \"text\": \"string\",\n },\n },\n overrides: {\n steps: {\n \"email-step\": {\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n },\n providers: {\n \"sendgrid\": {\n \"templateId\": \"1234567890\",\n },\n },\n },\n to: [\n \"SUBSCRIBER_ID\",\n \"SUBSCRIBER_ID\",\n ],\n },\n ],\n });\n\n // Handle the result\n console.log(result);\n}\n\nrun();" - target: $["paths"]["/v1/events/trigger/{transactionId}"]["delete"] update: "x-codeSamples": diff --git a/sources/json-development.json b/sources/json-development.json index 08d27ce0..5174ac50 100644 --- a/sources/json-development.json +++ b/sources/json-development.json @@ -8942,7 +8942,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/ActivitiesResponseDto" + "$ref": "#/components/schemas/MessagesResponseDto" } } } @@ -23357,7 +23357,7 @@ "info": { "title": "Novu API", "description": "Novu REST API. Please see https://docs.novu.co/api-reference for more details.", - "version": "1.0", + "version": "2.1.13", "contact": { "name": "Novu Support", "url": "https://discord.gg/novu", @@ -23391,13 +23391,6 @@ "url": "https://docs.novu.co/subscribers/topics" } }, - { - "name": "Notification", - "description": "A notification conveys information from source to recipient, triggered by a workflow acting as a message blueprint. Notifications can be individual or bundled as digest for user-friendliness.", - "externalDocs": { - "url": "https://docs.novu.co/getting-started/introduction" - } - }, { "name": "Integrations", "description": "With the help of the Integration Store, you can easily integrate your favorite delivery provider. During the runtime of the API, the Integrations Store is responsible for storing the configurations of all the providers.", @@ -23405,90 +23398,12 @@ "url": "https://docs.novu.co/channels-and-providers/integration-store" } }, - { - "name": "Layouts", - "description": "Novu allows the creation of layouts - a specific HTML design or structure to wrap content of email notifications. Layouts can be manipulated and assigned to new or existing workflows within the Novu platform, allowing users to create, manage, and assign these layouts to workflows, so they can be reused to structure the appearance of notifications sent through the platform.", - "externalDocs": { - "url": "https://docs.novu.co/content-creation-design/layouts" - } - }, - { - "name": "Workflows", - "description": "All notifications are sent via a workflow. Each workflow acts as a container for the logic and blueprint that are associated with a type of notification in your system.", - "externalDocs": { - "url": "https://docs.novu.co/workflows" - } - }, - { - "name": "Notification Templates", - "description": "Deprecated. Use Workflows (/workflows) instead, which provide the same functionality under a new name." - }, - { - "name": "Workflow groups", - "description": "Workflow groups are used to organize workflows into logical groups." - }, - { - "name": "Changes", - "description": "Changes represent a change in state of an environment. They are analagous to a pending pull request in git, enabling you to test changes before they are applied to your environment and atomically apply them when you are ready.", - "externalDocs": { - "url": "https://docs.novu.co/platform/environments#promoting-pending-changes-to-production" - } - }, - { - "name": "Environments", - "description": "Novu uses the concept of environments to ensure logical separation of your data and configuration. This means that subscribers, and preferences created in one environment are never accessible to another.", - "externalDocs": { - "url": "https://docs.novu.co/platform/environments" - } - }, - { - "name": "Inbound Parse", - "description": "Inbound Webhook is a feature that allows processing of incoming emails for a domain or subdomain. The feature parses the contents of the email and POSTs the information to a specified URL in a multipart/form-data format.", - "externalDocs": { - "url": "https://docs.novu.co/platform/inbound-parse-webhook" - } - }, - { - "name": "Feeds", - "description": "Novu provides a notification activity feed that monitors every outgoing message associated with its relevant metadata. This can be used to monitor activity and discover potential issues with a specific provider or a channel type.", - "externalDocs": { - "url": "https://docs.novu.co/activity-feed" - } - }, - { - "name": "Tenants", - "description": "A tenant represents a group of users. As a developer, when your apps have organizations, they are referred to as tenants. Tenants in Novu provides the ability to tailor specific notification experiences to users of different groups or organizations.", - "externalDocs": { - "url": "https://docs.novu.co/tenants" - } - }, { "name": "Messages", "description": "A message in Novu represents a notification delivered to a recipient on a particular channel. Messages contain information about the request that triggered its delivery, a view of the data sent to the recipient, and a timeline of its lifecycle events. Learn more about messages.", "externalDocs": { "url": "https://docs.novu.co/workflows/messages" } - }, - { - "name": "Organizations", - "description": "An organization serves as a separate entity within your Novu account. Each organization you create has its own separate integration store, workflows, subscribers, and API keys. This separation of resources allows you to manage multi-tenant environments and separate domains within a single account.", - "externalDocs": { - "url": "https://docs.novu.co/platform/organizations" - } - }, - { - "name": "Execution Details", - "description": "Execution details are used to track the execution of a workflow. They provided detailed information on the execution of a workflow, including the status of each step, the input and output of each step, and the overall status of the execution.", - "externalDocs": { - "url": "https://docs.novu.co/activity-feed" - } - }, - { - "name": "Translations", - "description": "Translations are used to localize your messages for different languages and regions. Novu provides a way to create and manage translations for your messages. You can create translations for your messages in different languages and regions, and assign them to your subscribers based on their preferences.", - "externalDocs": { - "url": "https://docs.novu.co/content-creation-design/translations" - } } ], "servers": [ @@ -23540,9 +23455,45 @@ "example": "/api/v1/resource" }, "message": { - "type": "string", - "description": "A detailed error message.", - "example": "Resource not found." + "description": "Value that failed validation", + "oneOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "nullable": true + }, + { + "type": "array", + "items": { + "anyOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "additionalProperties": true + } + ] + } + } + ], + "example": "xx xx xx " }, "ctx": { "type": "object", @@ -23562,8 +23513,66 @@ "required": [ "statusCode", "timestamp", - "path", - "message" + "path" + ] + }, + "ConstraintValidation": { + "type": "object", + "properties": { + "messages": { + "type": "array", + "items": { + "type": "string" + }, + "description": "List of validation error messages", + "example": [ + "Field is required", + "Invalid format" + ] + }, + "value": { + "description": "Value that failed validation", + "oneOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object" + }, + { + "type": "array", + "items": { + "anyOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "additionalProperties": true + } + ] + } + } + ], + "example": "xx xx xx " + } + }, + "required": [ + "messages" ] }, "ValidationErrorDto": { @@ -23585,9 +23594,45 @@ "example": "/api/v1/resource" }, "message": { - "type": "string", - "description": "A detailed error message.", - "example": "Resource not found." + "description": "Value that failed validation", + "oneOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "nullable": true + }, + { + "type": "array", + "items": { + "anyOf": [ + { + "type": "string", + "nullable": true + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "additionalProperties": true + } + ] + } + } + ], + "example": "xx xx xx " }, "ctx": { "type": "object", @@ -23607,51 +23652,7 @@ "type": "object", "description": "A record of validation errors keyed by field name", "additionalProperties": { - "type": "object", - "properties": { - "messages": { - "type": "array", - "items": { - "type": "string" - } - }, - "value": { - "oneOf": [ - { - "type": "string", - "nullable": true - }, - { - "type": "number" - }, - { - "type": "boolean" - }, - { - "type": "object", - "additionalProperties": true - }, - { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - } - ] - } - }, - "required": [ - "messages", - "value" - ], - "example": { - "messages": [ - "Field is required", - "Invalid format" - ], - "value": "xx xx xx " - } + "$ref": "#/components/schemas/ConstraintValidation" }, "example": { "fieldName1": { @@ -23680,6 +23681,17 @@ "value": { "key": "value" } + }, + "fieldName5": { + "messages": [ + "Field is missing" + ], + "value": null + }, + "fieldName6": { + "messages": [ + "Undefined value" + ] } } } @@ -23688,7 +23700,6 @@ "statusCode", "timestamp", "path", - "message", "errors" ] }, @@ -23991,59 +24002,143 @@ "type" ] }, - "TriggerEventRequestDto": { + "StepsOverrides": { "type": "object", "properties": { - "name": { - "type": "string", - "description": "The trigger identifier of the workflow you wish to send. This identifier can be found on the workflow page.", - "example": "workflow_identifier", - "x-speakeasy-name-override": "workflowId" - }, - "payload": { + "providers": { "type": "object", - "description": "The payload object is used to pass additional custom information that could be \n used to render the workflow, or perform routing rules based on it. \n This data will also be available when fetching the notifications feed from the API to display certain parts of the UI.", - "additionalProperties": true, + "description": "Passing the provider id and the provider specific configurations", "example": { - "comment_id": "string", - "post": { - "text": "string" + "sendgrid": { + "templateId": "1234567890" } + }, + "additionalProperties": { + "type": "object", + "additionalProperties": true } - }, - "overrides": { + } + }, + "required": [ + "providers" + ] + }, + "TriggerOverrides": { + "type": "object", + "properties": { + "steps": { "type": "object", "description": "This could be used to override provider specific configurations", "example": { - "fcm": { - "data": { - "key": "value" + "email-step": { + "providers": { + "sendgrid": { + "templateId": "1234567890" + } } } }, + "additionalProperties": { + "$ref": "#/components/schemas/StepsOverrides" + } + }, + "providers": { + "type": "object", + "description": "Overrides the provider configuration for the entire workflow and all steps", + "example": { + "sendgrid": { + "templateId": "1234567890" + } + }, "additionalProperties": { "type": "object", "additionalProperties": true } }, - "to": { - "description": "The recipients list of people who will receive the notification.", - "oneOf": [ - { - "type": "array", - "items": { - "oneOf": [ - { - "$ref": "#/components/schemas/SubscriberPayloadDto" - }, - { - "$ref": "#/components/schemas/TopicPayloadDto" - }, - { - "type": "string", - "description": "Unique identifier of a subscriber in your systems", - "example": "SUBSCRIBER_ID" - } + "email": { + "type": "object", + "description": "Override the email provider specific configurations for the entire workflow", + "deprecated": true, + "additionalProperties": true + }, + "push": { + "type": "object", + "description": "Override the push provider specific configurations for the entire workflow", + "deprecated": true, + "additionalProperties": true + }, + "sms": { + "type": "object", + "description": "Override the sms provider specific configurations for the entire workflow", + "deprecated": true, + "additionalProperties": true + }, + "chat": { + "type": "object", + "description": "Override the chat provider specific configurations for the entire workflow", + "deprecated": true, + "additionalProperties": true + }, + "layoutIdentifier": { + "type": "string", + "description": "Override the layout identifier for the entire workflow", + "deprecated": true + } + } + }, + "TriggerEventRequestDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "The trigger identifier of the workflow you wish to send. This identifier can be found on the workflow page.", + "example": "workflow_identifier", + "x-speakeasy-name-override": "workflowId" + }, + "payload": { + "type": "object", + "description": "The payload object is used to pass additional custom information that could be \n used to render the workflow, or perform routing rules based on it. \n This data will also be available when fetching the notifications feed from the API to display certain parts of the UI.", + "additionalProperties": true, + "example": { + "comment_id": "string", + "post": { + "text": "string" + } + } + }, + "overrides": { + "description": "This could be used to override provider specific configurations", + "example": { + "fcm": { + "data": { + "key": "value" + } + } + }, + "allOf": [ + { + "$ref": "#/components/schemas/TriggerOverrides" + } + ] + }, + "to": { + "description": "The recipients list of people who will receive the notification.", + "oneOf": [ + { + "type": "array", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/SubscriberPayloadDto" + }, + { + "$ref": "#/components/schemas/TopicPayloadDto" + }, + { + "type": "string", + "description": "Unique identifier of a subscriber in your systems", + "example": "SUBSCRIBER_ID" + } ] } }, @@ -24127,7 +24222,6 @@ "additionalProperties": true }, "overrides": { - "type": "object", "description": "This could be used to override provider specific configurations", "example": { "fcm": { @@ -24135,7 +24229,16 @@ "key": "value" } } - } + }, + "additionalProperties": { + "type": "object", + "additionalProperties": true + }, + "allOf": [ + { + "$ref": "#/components/schemas/TriggerOverrides" + } + ] }, "transactionId": { "type": "string", @@ -24184,7 +24287,7 @@ }, "StepTypeEnum": { "type": "string", - "description": "Channels of the notification", + "description": "Type of the step", "enum": [ "in_app", "email", @@ -24544,6 +24647,7 @@ "brevo-sms", "eazy-sms", "mobishastra", + "afro-message", "fcm", "apns", "expo", @@ -25379,6 +25483,29 @@ "data" ] }, + "ChatOrPushProviderEnum": { + "type": "string", + "description": "The provider identifier for the credentials", + "enum": [ + "slack", + "discord", + "msteams", + "mattermost", + "ryver", + "zulip", + "grafana-on-call", + "getstream", + "rocket-chat", + "whatsapp-business", + "fcm", + "apns", + "expo", + "one-signal", + "pushpad", + "push-webhook", + "pusher-beams" + ] + }, "ChannelCredentials": { "type": "object", "properties": { @@ -25435,27 +25562,7 @@ "type": "object", "properties": { "providerId": { - "type": "string", - "enum": [ - "slack", - "discord", - "msteams", - "mattermost", - "ryver", - "zulip", - "grafana-on-call", - "getstream", - "rocket-chat", - "whatsapp-business", - "fcm", - "apns", - "expo", - "one-signal", - "pushpad", - "push-webhook", - "pusher-beams" - ], - "description": "The provider identifier for the credentials" + "$ref": "#/components/schemas/ChatOrPushProviderEnum" }, "integrationIdentifier": { "type": "string", @@ -25497,7 +25604,6 @@ }, "email": { "type": "string", - "nullable": true, "description": "The email address of the subscriber." }, "phone": { @@ -25512,10 +25618,6 @@ "type": "string", "description": "The locale setting of the subscriber, indicating their preferred language or region." }, - "subscriberId": { - "type": "string", - "description": "The identifier used to create this subscriber, which typically corresponds to the user ID in your system." - }, "channels": { "description": "An array of channel settings associated with the subscriber.", "type": "array", @@ -25539,6 +25641,24 @@ "type": "string", "description": "The timestamp indicating when the subscriber was last online, in ISO 8601 format." }, + "__v": { + "type": "number", + "description": "The version of the subscriber document." + }, + "data": { + "type": "object", + "description": "Additional custom data for the subscriber", + "additionalProperties": true, + "nullable": true + }, + "timezone": { + "type": "string", + "description": "Timezone of the subscriber" + }, + "subscriberId": { + "type": "string", + "description": "The identifier used to create this subscriber, which typically corresponds to the user ID in your system." + }, "_organizationId": { "type": "string", "description": "The unique identifier of the organization to which the subscriber belongs." @@ -25558,20 +25678,6 @@ "updatedAt": { "type": "string", "description": "The timestamp indicating when the subscriber was last updated, in ISO 8601 format." - }, - "__v": { - "type": "number", - "description": "The version of the subscriber document." - }, - "data": { - "type": "object", - "description": "Additional custom data for the subscriber", - "additionalProperties": true, - "nullable": true - }, - "timezone": { - "type": "string", - "description": "Timezone of the subscriber" } }, "required": [ @@ -25656,7 +25762,6 @@ "properties": { "subscriberId": { "type": "string", - "pattern": "VALID_ID_REGEX", "description": "Unique identifier of the subscriber" }, "firstName": { @@ -25781,27 +25886,7 @@ "type": "object", "properties": { "providerId": { - "type": "string", - "enum": [ - "slack", - "discord", - "msteams", - "mattermost", - "ryver", - "zulip", - "grafana-on-call", - "getstream", - "rocket-chat", - "whatsapp-business", - "fcm", - "apns", - "expo", - "one-signal", - "pushpad", - "push-webhook", - "pusher-beams" - ], - "description": "The provider identifier for the credentials" + "$ref": "#/components/schemas/ChatOrPushProviderEnum" }, "integrationIdentifier": { "type": "string", @@ -25997,10 +26082,7 @@ } ] } - }, - "required": [ - "data" - ] + } }, "ActorTypeEnum": { "type": "string", @@ -26177,11 +26259,6 @@ "description": "Indicates whether the notification has been seen by the subscriber.", "example": true }, - "deleted": { - "type": "boolean", - "description": "Indicates whether the notification has been deleted.", - "example": false - }, "deviceTokens": { "nullable": true, "description": "Device tokens for push notifications, if applicable.", @@ -26244,7 +26321,6 @@ "channel", "read", "seen", - "deleted", "cta", "status" ] @@ -26323,23 +26399,33 @@ "_organizationId" ] }, - "PreferenceChannels": { + "SubscriberPreferenceChannels": { "type": "object", "properties": { "email": { - "type": "boolean" + "type": "boolean", + "description": "Email channel preference", + "example": true }, "sms": { - "type": "boolean" + "type": "boolean", + "description": "SMS channel preference", + "example": false }, "in_app": { - "type": "boolean" + "type": "boolean", + "description": "In-app channel preference", + "example": true }, "chat": { - "type": "boolean" + "type": "boolean", + "description": "Chat channel preference", + "example": false }, "push": { - "type": "boolean" + "type": "boolean", + "description": "Push notification channel preference", + "example": true } } }, @@ -26756,7 +26842,7 @@ "type": "boolean" }, "preferenceSettings": { - "$ref": "#/components/schemas/PreferenceChannels" + "$ref": "#/components/schemas/SubscriberPreferenceChannels" }, "critical": { "type": "boolean" @@ -26896,6 +26982,13 @@ "type": "string", "description": "Creation date of the message" }, + "deliveredAt": { + "description": "Array of delivery dates for the message, if the message has multiple delivery dates, for example after being snoozed", + "type": "array", + "items": { + "type": "string" + } + }, "lastSeenDate": { "type": "string", "description": "Last seen date of the message, if available" @@ -26907,7 +27000,10 @@ "content": { "oneOf": [ { - "$ref": "#/components/schemas/EmailBlock" + "type": "array", + "items": { + "$ref": "#/components/schemas/EmailBlock" + } }, { "type": "string", @@ -26935,6 +27031,10 @@ "type": "boolean", "description": "Indicates if the message has been seen" }, + "snoozedUntil": { + "type": "string", + "description": "Date when the message will be unsnoozed" + }, "email": { "type": "string", "description": "Email address associated with the message, if applicable" @@ -27190,7 +27290,7 @@ "status" ] }, - "GlobalPreferenceDto": { + "SubscriberGlobalPreferenceDto": { "type": "object", "properties": { "enabled": { @@ -27201,7 +27301,7 @@ "description": "Channel-specific preference settings", "allOf": [ { - "$ref": "#/components/schemas/PreferenceChannels" + "$ref": "#/components/schemas/SubscriberPreferenceChannels" } ] } @@ -27211,28 +27311,23 @@ "channels" ] }, - "Overrides": { + "PreferenceOverrideSourceEnum": { + "type": "string", + "description": "The source of overrides", + "enum": [ + "subscriber", + "template", + "workflowOverride" + ] + }, + "SubscriberPreferenceOverrideDto": { "type": "object", "properties": { "channel": { - "enum": [ - "in_app", - "email", - "sms", - "chat", - "push" - ], - "type": "string", - "description": "The channel type which is overridden" + "$ref": "#/components/schemas/ChannelTypeEnum" }, "source": { - "enum": [ - "subscriber", - "template", - "workflowOverride" - ], - "type": "string", - "description": "The source of overrides" + "$ref": "#/components/schemas/PreferenceOverrideSourceEnum" } }, "required": [ @@ -27240,7 +27335,7 @@ "source" ] }, - "WorkflowInfoDto": { + "SubscriberPreferencesWorkflowInfoDto": { "type": "object", "properties": { "slug": { @@ -27266,7 +27361,7 @@ "name" ] }, - "WorkflowPreferenceDto": { + "SubscriberWorkflowPreferenceDto": { "type": "object", "properties": { "enabled": { @@ -27277,7 +27372,7 @@ "description": "Channel-specific preference settings for this workflow", "allOf": [ { - "$ref": "#/components/schemas/PreferenceChannels" + "$ref": "#/components/schemas/SubscriberPreferenceChannels" } ] }, @@ -27285,14 +27380,14 @@ "description": "List of preference overrides", "type": "array", "items": { - "$ref": "#/components/schemas/Overrides" + "$ref": "#/components/schemas/SubscriberPreferenceOverrideDto" } }, "workflow": { "description": "Workflow information", "allOf": [ { - "$ref": "#/components/schemas/WorkflowInfoDto" + "$ref": "#/components/schemas/SubscriberPreferencesWorkflowInfoDto" } ] } @@ -27311,7 +27406,7 @@ "description": "Global preference settings", "allOf": [ { - "$ref": "#/components/schemas/GlobalPreferenceDto" + "$ref": "#/components/schemas/SubscriberGlobalPreferenceDto" } ] }, @@ -27319,7 +27414,7 @@ "description": "Workflow-specific preference settings", "type": "array", "items": { - "$ref": "#/components/schemas/WorkflowPreferenceDto" + "$ref": "#/components/schemas/SubscriberWorkflowPreferenceDto" } } }, @@ -27366,33 +27461,67 @@ }, "workflowId": { "type": "string", - "description": "If provided, update workflow specific preferences, otherwise update global preferences" + "description": "Workflow internal _id, identifier or slug. If provided, update workflow specific preferences, otherwise update global preferences" } }, "required": [ "channels" ] }, - "DeleteMessageResponseDto": { + "MessagesResponseDto": { "type": "object", "properties": { - "acknowledged": { + "totalCount": { + "type": "number", + "description": "Total number of messages available" + }, + "hasMore": { "type": "boolean", - "description": "A boolean stating the success of the action" + "description": "Indicates if there are more messages available" }, - "status": { - "type": "string", - "description": "The status enum for the performed action", - "enum": [ - "deleted" - ] - } - }, - "required": [ - "acknowledged", - "status" - ] - }, + "data": { + "description": "List of messages", + "type": "array", + "items": { + "$ref": "#/components/schemas/MessageResponseDto" + } + }, + "pageSize": { + "type": "number", + "description": "Number of messages per page" + }, + "page": { + "type": "number", + "description": "Current page number" + } + }, + "required": [ + "hasMore", + "data", + "pageSize", + "page" + ] + }, + "DeleteMessageResponseDto": { + "type": "object", + "properties": { + "acknowledged": { + "type": "boolean", + "description": "A boolean stating the success of the action" + }, + "status": { + "type": "string", + "description": "The status enum for the performed action", + "enum": [ + "deleted" + ] + } + }, + "required": [ + "acknowledged", + "status" + ] + }, "CreateTopicResponseDto": { "type": "object", "properties": { @@ -27679,9 +27808,1612 @@ "name" ] }, - "GeneratePreviewResponseDto": { + "RuntimeIssueDto": { "type": "object", - "properties": {} + "properties": { + "issueType": { + "enum": [ + "MISSING_VALUE", + "MAX_LENGTH_ACCESSED", + "WORKFLOW_ID_ALREADY_EXISTS", + "DUPLICATED_VALUE", + "LIMIT_REACHED" + ], + "type": "string" + }, + "variableName": { + "type": "string" + }, + "message": { + "type": "string" + } + }, + "required": [ + "issueType", + "message" + ] + }, + "JsonSchemaTypeEnum": { + "type": "string", + "description": "JSON Schema type", + "enum": [ + "string", + "number", + "integer", + "boolean", + "array", + "object", + "null" + ] + }, + "JsonSchemaFormatEnum": { + "type": "string", + "description": "Format validation for strings", + "enum": [ + "date", + "time", + "date-time", + "duration", + "email", + "hostname", + "idn-hostname", + "ipv4", + "ipv6", + "json-pointer", + "relative-json-pointer", + "regex", + "uri", + "uri-reference", + "uri-template", + "url", + "uuid", + "guid", + "phone", + "password", + "color" + ] + }, + "JSONSchemaDto": { + "type": "object", + "properties": { + "type": { + "$ref": "#/components/schemas/JsonSchemaTypeEnum" + }, + "format": { + "$ref": "#/components/schemas/JsonSchemaFormatEnum" + }, + "title": { + "type": "string", + "description": "Title of the schema" + }, + "description": { + "type": "string", + "description": "Description of the schema" + }, + "default": { + "description": "Default value", + "oneOf": [ + { + "type": "string" + }, + { + "type": "number" + }, + { + "type": "boolean" + } + ] + }, + "const": { + "type": "object", + "description": "Const value (exact match required)" + }, + "minimum": { + "type": "number", + "description": "Minimum value for numbers" + }, + "maximum": { + "type": "number", + "description": "Maximum value for numbers" + }, + "exclusiveMinimum": { + "type": "boolean", + "description": "Exclusive minimum" + }, + "exclusiveMaximum": { + "type": "boolean", + "description": "Exclusive maximum" + }, + "minLength": { + "type": "number", + "description": "Minimum length for strings" + }, + "maxLength": { + "type": "number", + "description": "Maximum length for strings" + }, + "pattern": { + "type": "string", + "description": "Regular expression pattern" + }, + "minItems": { + "type": "number", + "description": "Minimum number of items in array" + }, + "maxItems": { + "type": "number", + "description": "Maximum number of items in array" + }, + "uniqueItems": { + "type": "boolean", + "description": "Items must be unique" + }, + "items": { + "description": "Schema for array items", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "required": { + "type": "array", + "description": "Required properties for object", + "items": { + "type": "string" + } + }, + "properties": { + "type": "object", + "description": "Object properties", + "additionalProperties": { + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "additionalProperties": { + "description": "Additional properties schema", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + }, + { + "type": "boolean" + } + ] + }, + "enum": { + "type": "array", + "description": "Enumeration of possible values", + "items": { + "type": "string" + } + }, + "allOf": { + "type": "array", + "description": "Combination of schemas (allOf)", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "anyOf": { + "type": "array", + "description": "At least one schema must match (anyOf)", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "oneOf": { + "type": "array", + "description": "Only one schema must match (oneOf)", + "items": { + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "not": { + "description": "Schema must not match (not)", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "if": { + "description": "Conditional validation schema (if condition)", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "then": { + "description": "Schema to apply if \"if\" condition is true", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "else": { + "description": "Schema to apply if \"if\" condition is false", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "contentEncoding": { + "type": "string", + "description": "Content encoding (e.g., base64)" + }, + "contentMediaType": { + "type": "string", + "description": "Content media type" + }, + "dependentRequired": { + "type": "object", + "description": "Dependent required properties", + "additionalProperties": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "dependentSchemas": { + "type": "object", + "description": "Dependent schemas", + "additionalProperties": { + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "$schema": { + "type": "string", + "description": "JSON Schema version" + }, + "$id": { + "type": "string", + "description": "Unique identifier for the schema" + }, + "contentSchema": { + "description": "Content schema for specific types", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "examples": { + "type": "array", + "description": "Example values", + "items": { + "type": "object" + } + }, + "multipleOf": { + "type": "number", + "description": "Minimum number of decimal places" + } + } + }, + "UiComponentEnum": { + "type": "string", + "description": "Component type for the UI Schema Property", + "enum": [ + "BLOCK_EDITOR", + "TEXT_FULL_LINE", + "TEXT_INLINE_LABEL", + "IN_APP_BODY", + "IN_APP_AVATAR", + "IN_APP_PRIMARY_SUBJECT", + "IN_APP_BUTTON_DROPDOWN", + "IN_APP_DISABLE_SANITIZATION_SWITCH", + "DISABLE_SANITIZATION_SWITCH", + "URL_TEXT_BOX", + "DIGEST_AMOUNT", + "DIGEST_UNIT", + "DIGEST_KEY", + "DIGEST_CRON", + "DELAY_TYPE", + "DELAY_AMOUNT", + "DELAY_UNIT", + "SMS_BODY", + "CHAT_BODY", + "PUSH_BODY", + "PUSH_SUBJECT", + "QUERY_EDITOR", + "DATA" + ] + }, + "UiSchemaProperty": { + "type": "object", + "properties": { + "placeholder": { + "description": "Placeholder for the UI Schema Property", + "anyOf": [ + { + "type": "string" + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "additionalProperties": true + }, + { + "type": "array", + "items": { + "anyOf": [ + { + "type": "string" + }, + { + "type": "number" + }, + { + "type": "boolean" + }, + { + "type": "object", + "additionalProperties": true + } + ] + } + } + ], + "nullable": true + }, + "component": { + "$ref": "#/components/schemas/UiComponentEnum" + } + }, + "required": [ + "component" + ] + }, + "UiSchemaGroupEnum": { + "type": "string", + "description": "Group of the UI Schema", + "enum": [ + "IN_APP", + "EMAIL", + "DIGEST", + "DELAY", + "SMS", + "CHAT", + "PUSH", + "SKIP" + ] + }, + "UiSchema": { + "type": "object", + "properties": { + "group": { + "$ref": "#/components/schemas/UiSchemaGroupEnum" + }, + "properties": { + "type": "object", + "description": "Properties of the UI Schema", + "additionalProperties": { + "$ref": "#/components/schemas/UiSchemaProperty" + } + } + } + }, + "ControlsMetadataDto": { + "type": "object", + "properties": { + "dataSchema": { + "description": "JSON Schema for data", + "oneOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ], + "allOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "uiSchema": { + "description": "UI Schema for rendering", + "allOf": [ + { + "$ref": "#/components/schemas/UiSchema" + } + ] + }, + "values": { + "type": "object", + "description": "Control values", + "additionalProperties": true + } + }, + "required": [ + "values" + ] + }, + "StepContentIssueEnum": { + "type": "string", + "description": "Type of step content issue", + "enum": [ + "ILLEGAL_VARIABLE_IN_CONTROL_VALUE", + "INVALID_FILTER_ARG_IN_VARIABLE", + "MISSING_VALUE", + "TIER_LIMIT_EXCEEDED" + ] + }, + "StepContentIssueDto": { + "type": "object", + "properties": { + "issueType": { + "$ref": "#/components/schemas/StepContentIssueEnum" + }, + "variableName": { + "type": "string", + "description": "Name of the variable related to the issue" + }, + "message": { + "type": "string", + "description": "Detailed message describing the issue" + } + }, + "required": [ + "issueType", + "message" + ] + }, + "StepIntegrationIssueEnum": { + "type": "string", + "description": "Type of integration issue", + "enum": [ + "MISSING_INTEGRATION" + ] + }, + "StepIntegrationIssue": { + "type": "object", + "properties": { + "issueType": { + "$ref": "#/components/schemas/StepIntegrationIssueEnum" + }, + "variableName": { + "type": "string", + "description": "Name of the variable related to the issue" + }, + "message": { + "type": "string", + "description": "Detailed message describing the issue" + } + }, + "required": [ + "issueType", + "message" + ] + }, + "StepIssuesDto": { + "type": "object", + "properties": { + "controls": { + "type": "object", + "description": "Controls-related issues", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/components/schemas/StepContentIssueDto" + } + } + }, + "integration": { + "type": "object", + "description": "Integration-related issues", + "additionalProperties": { + "type": "array", + "items": { + "$ref": "#/components/schemas/StepIntegrationIssue" + } + } + } + } + }, + "StepResponseDto": { + "type": "object", + "properties": { + "controls": { + "description": "Controls metadata for the step", + "allOf": [ + { + "$ref": "#/components/schemas/ControlsMetadataDto" + } + ] + }, + "variables": { + "description": "JSON Schema for variables", + "allOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "stepId": { + "type": "string", + "description": "Unique identifier of the step" + }, + "_id": { + "type": "string", + "description": "Database identifier of the step" + }, + "name": { + "type": "string", + "description": "Name of the step" + }, + "slug": { + "type": "object", + "description": "Slug of the step" + }, + "type": { + "$ref": "#/components/schemas/StepTypeEnum" + }, + "origin": { + "$ref": "#/components/schemas/WorkflowOriginEnum" + }, + "workflowId": { + "type": "string", + "description": "Workflow identifier" + }, + "workflowDatabaseId": { + "type": "string", + "description": "Workflow database identifier" + }, + "issues": { + "description": "Issues associated with the step", + "allOf": [ + { + "$ref": "#/components/schemas/StepIssuesDto" + } + ] + } + }, + "required": [ + "controls", + "variables", + "stepId", + "_id", + "name", + "slug", + "type", + "origin", + "workflowId", + "workflowDatabaseId" + ] + }, + "WorkflowPreferenceDto": { + "type": "object", + "properties": { + "enabled": { + "type": "boolean", + "default": true, + "description": "A flag specifying if notification delivery is enabled for the workflow. If true, notification delivery is enabled by default for all channels. This setting can be overridden by the channel preferences." + }, + "readOnly": { + "type": "boolean", + "default": false, + "description": "A flag specifying if the preference is read-only. If true, the preference cannot be changed by the Subscriber." + } + }, + "required": [ + "enabled", + "readOnly" + ] + }, + "ChannelPreferenceDto": { + "type": "object", + "properties": { + "enabled": { + "type": "boolean", + "default": true, + "description": "A flag specifying if notification delivery is enabled for the channel. If true, notification delivery is enabled." + } + }, + "required": [ + "enabled" + ] + }, + "WorkflowPreferencesDto": { + "type": "object", + "properties": { + "all": { + "description": "A preference for the workflow. The values specified here will be used if no preference is specified for a channel.", + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferenceDto" + } + ], + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferenceDto" + } + ] + }, + "channels": { + "type": "object", + "description": "Preferences for different communication channels", + "additionalProperties": { + "$ref": "#/components/schemas/ChannelPreferenceDto" + }, + "example": { + "email": { + "enabled": true + }, + "sms": { + "enabled": false + } + } + } + }, + "required": [ + "all", + "channels" + ] + }, + "WorkflowPreferencesResponseDto": { + "type": "object", + "properties": { + "user": { + "nullable": true, + "description": "User-specific workflow preferences", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferencesDto" + } + ] + }, + "default": { + "description": "Default workflow preferences", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferencesDto" + } + ] + } + }, + "required": [ + "default" + ] + }, + "WorkflowStatusEnum": { + "type": "string", + "description": "Status of the workflow", + "enum": [ + "ACTIVE", + "INACTIVE", + "ERROR" + ] + }, + "WorkflowResponseDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the workflow" + }, + "description": { + "type": "string", + "description": "Description of the workflow" + }, + "tags": { + "description": "Tags associated with the workflow", + "type": "array", + "items": { + "type": "string" + } + }, + "active": { + "type": "boolean", + "description": "Whether the workflow is active", + "default": false + }, + "_id": { + "type": "string", + "description": "Unique identifier of the workflow" + }, + "workflowId": { + "type": "string", + "description": "Workflow identifier" + }, + "slug": { + "type": "object", + "description": "Slug of the workflow" + }, + "updatedAt": { + "type": "string", + "description": "Last updated timestamp" + }, + "createdAt": { + "type": "string", + "description": "Creation timestamp" + }, + "steps": { + "description": "Steps of the workflow", + "type": "array", + "items": { + "$ref": "#/components/schemas/StepResponseDto" + } + }, + "origin": { + "$ref": "#/components/schemas/WorkflowOriginEnum" + }, + "preferences": { + "description": "Preferences for the workflow", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferencesResponseDto" + } + ] + }, + "status": { + "$ref": "#/components/schemas/WorkflowStatusEnum" + }, + "issues": { + "type": "object", + "description": "Runtime issues for workflow creation and update", + "additionalProperties": { + "$ref": "#/components/schemas/RuntimeIssueDto" + } + }, + "lastTriggeredAt": { + "type": "string", + "description": "Timestamp of the last workflow trigger", + "nullable": true + } + }, + "required": [ + "name", + "_id", + "workflowId", + "slug", + "updatedAt", + "createdAt", + "steps", + "origin", + "preferences", + "status" + ] + }, + "StepUpsertDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the step" + }, + "_id": { + "type": "string", + "description": "Unique identifier of the step" + }, + "type": { + "$ref": "#/components/schemas/StepTypeEnum" + }, + "controlValues": { + "type": "object", + "nullable": true, + "description": "Control values for the step", + "additionalProperties": true + } + }, + "required": [ + "name", + "type" + ] + }, + "WorkflowCreationSourceEnum": { + "type": "string", + "description": "Source of workflow creation", + "enum": [ + "template_store", + "editor", + "notification_directory", + "onboarding_digest_demo", + "onboarding_in_app", + "empty_state", + "dropdown", + "onboarding_get_started", + "bridge", + "dashboard" + ] + }, + "PreferencesRequestDto": { + "type": "object", + "properties": { + "user": { + "nullable": true, + "description": "User workflow preferences", + "oneOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferencesDto" + } + ] + }, + "workflow": { + "nullable": true, + "description": "Workflow-specific preferences", + "allOf": [ + { + "$ref": "#/components/schemas/WorkflowPreferencesDto" + } + ] + } + } + }, + "CreateWorkflowDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the workflow" + }, + "description": { + "type": "string", + "description": "Description of the workflow" + }, + "tags": { + "description": "Tags associated with the workflow", + "type": "array", + "items": { + "type": "string" + } + }, + "active": { + "type": "boolean", + "description": "Whether the workflow is active", + "default": false + }, + "workflowId": { + "type": "string", + "description": "Unique identifier for the workflow" + }, + "steps": { + "description": "Steps of the workflow", + "type": "array", + "items": { + "$ref": "#/components/schemas/StepUpsertDto" + } + }, + "__source": { + "$ref": "#/components/schemas/WorkflowCreationSourceEnum" + }, + "preferences": { + "description": "Workflow preferences", + "allOf": [ + { + "$ref": "#/components/schemas/PreferencesRequestDto" + } + ] + } + }, + "required": [ + "name", + "workflowId", + "steps", + "__source" + ] + }, + "SyncWorkflowDto": { + "type": "object", + "properties": { + "targetEnvironmentId": { + "type": "string", + "description": "Target environment identifier to sync the workflow to" + } + }, + "required": [ + "targetEnvironmentId" + ] + }, + "UpdateWorkflowDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the workflow" + }, + "description": { + "type": "string", + "description": "Description of the workflow" + }, + "tags": { + "description": "Tags associated with the workflow", + "type": "array", + "items": { + "type": "string" + } + }, + "active": { + "type": "boolean", + "description": "Whether the workflow is active", + "default": false + }, + "workflowId": { + "type": "string", + "description": "Workflow ID (allowed only for code-first workflows)" + }, + "steps": { + "type": "array", + "description": "Steps of the workflow", + "items": { + "$ref": "#/components/schemas/StepUpsertDto" + } + }, + "preferences": { + "description": "Workflow preferences", + "allOf": [ + { + "$ref": "#/components/schemas/PreferencesRequestDto" + } + ] + }, + "origin": { + "$ref": "#/components/schemas/WorkflowOriginEnum" + } + }, + "required": [ + "name", + "steps", + "preferences", + "origin" + ] + }, + "WorkflowListResponseDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the workflow" + }, + "tags": { + "type": "array", + "description": "Tags associated with the workflow", + "items": { + "type": "string" + } + }, + "updatedAt": { + "type": "string", + "description": "Last updated timestamp" + }, + "createdAt": { + "type": "string", + "description": "Creation timestamp" + }, + "_id": { + "type": "string", + "description": "Unique database identifier" + }, + "workflowId": { + "type": "string", + "description": "Workflow identifier" + }, + "slug": { + "type": "string", + "description": "Workflow slug" + }, + "status": { + "$ref": "#/components/schemas/WorkflowStatusEnum" + }, + "origin": { + "$ref": "#/components/schemas/WorkflowOriginEnum" + }, + "lastTriggeredAt": { + "type": "string", + "description": "Timestamp of the last workflow trigger", + "nullable": true + }, + "stepTypeOverviews": { + "type": "array", + "items": { + "$ref": "#/components/schemas/StepTypeEnum" + }, + "description": "Overview of step types in the workflow" + } + }, + "required": [ + "name", + "updatedAt", + "createdAt", + "_id", + "workflowId", + "slug", + "status", + "origin", + "stepTypeOverviews" + ] + }, + "ListWorkflowResponse": { + "type": "object", + "properties": { + "workflows": { + "description": "List of workflows", + "type": "array", + "items": { + "$ref": "#/components/schemas/WorkflowListResponseDto" + } + }, + "totalCount": { + "type": "number", + "description": "Total number of workflows" + } + }, + "required": [ + "workflows", + "totalCount" + ] + }, + "DirectionEnum": { + "type": "string", + "enum": [ + "ASC", + "DESC" + ] + }, + "WorkflowResponseDtoSortField": { + "type": "string", + "enum": [ + "createdAt", + "updatedAt", + "name", + "lastTriggeredAt" + ] + }, + "DuplicateWorkflowDto": { + "type": "object", + "properties": { + "name": { + "type": "string", + "description": "Name of the workflow" + }, + "tags": { + "description": "Tags associated with the workflow", + "type": "array", + "items": { + "type": "string" + } + }, + "description": { + "type": "string", + "description": "Description of the workflow" + } + } + }, + "EmailRenderOutput": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the email" + }, + "body": { + "type": "string", + "description": "Body of the email" + } + }, + "required": [ + "subject", + "body" + ] + }, + "RedirectTargetEnum": { + "type": "string", + "description": "Target of the redirect", + "enum": [ + "_self", + "_blank", + "_parent", + "_top", + "_unfencedTop" + ] + }, + "RedirectDto": { + "type": "object", + "properties": { + "url": { + "type": "string", + "description": "URL to redirect to" + }, + "target": { + "$ref": "#/components/schemas/RedirectTargetEnum" + } + }, + "required": [ + "url" + ] + }, + "ActionDto": { + "type": "object", + "properties": { + "label": { + "type": "string", + "description": "Label for the action" + }, + "redirect": { + "description": "Redirect details for the action", + "allOf": [ + { + "$ref": "#/components/schemas/RedirectDto" + } + ] + } + }, + "required": [ + "label" + ] + }, + "InAppRenderOutput": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the in-app notification" + }, + "body": { + "type": "string", + "description": "Body of the in-app notification" + }, + "avatar": { + "type": "string", + "description": "Avatar for the in-app notification" + }, + "primaryAction": { + "description": "Primary action details", + "allOf": [ + { + "$ref": "#/components/schemas/ActionDto" + } + ] + }, + "secondaryAction": { + "description": "Secondary action details", + "allOf": [ + { + "$ref": "#/components/schemas/ActionDto" + } + ] + }, + "data": { + "type": "object", + "description": "Additional data", + "additionalProperties": true + }, + "redirect": { + "description": "Redirect details", + "allOf": [ + { + "$ref": "#/components/schemas/RedirectDto" + } + ] + } + }, + "required": [ + "body" + ] + }, + "SmsRenderOutput": { + "type": "object", + "properties": { + "body": { + "type": "string", + "description": "Body of the SMS message" + } + }, + "required": [ + "body" + ] + }, + "PushRenderOutput": { + "type": "object", + "properties": { + "subject": { + "type": "string", + "description": "Subject of the push notification" + }, + "body": { + "type": "string", + "description": "Body of the push notification" + } + }, + "required": [ + "subject", + "body" + ] + }, + "ChatRenderOutput": { + "type": "object", + "properties": { + "body": { + "type": "string", + "description": "Body of the chat message" + } + }, + "required": [ + "body" + ] + }, + "TimeUnitEnum": { + "type": "string", + "description": "Time unit", + "enum": [ + "seconds", + "minutes", + "hours", + "days", + "weeks", + "months" + ] + }, + "DigestRegularOutput": { + "type": "object", + "properties": { + "amount": { + "type": "number", + "description": "Amount of time units" + }, + "unit": { + "$ref": "#/components/schemas/TimeUnitEnum" + }, + "digestKey": { + "type": "string", + "description": "Optional digest key" + }, + "lookBackWindow": { + "type": "object", + "description": "Look back window configuration" + } + }, + "required": [ + "amount", + "unit" + ] + }, + "DigestTimedOutput": { + "type": "object", + "properties": { + "cron": { + "type": "string", + "description": "Cron expression" + }, + "digestKey": { + "type": "string", + "description": "Optional digest key" + } + }, + "required": [ + "cron" + ] + }, + "DelayRenderOutput": { + "type": "object", + "properties": { + "type": { + "type": "string", + "description": "Type of delay" + }, + "amount": { + "type": "number", + "description": "Amount of time units" + }, + "unit": { + "$ref": "#/components/schemas/TimeUnitEnum" + } + }, + "required": [ + "type", + "amount", + "unit" + ] + }, + "SubscriberResponseDtoOptional": { + "type": "object", + "properties": { + "_id": { + "type": "string", + "description": "The internal ID generated by Novu for your subscriber. This ID does not match the `subscriberId` used in your queries. Refer to `subscriberId` for that identifier." + }, + "firstName": { + "type": "string", + "description": "The first name of the subscriber." + }, + "lastName": { + "type": "string", + "description": "The last name of the subscriber." + }, + "email": { + "type": "string", + "description": "The email address of the subscriber." + }, + "phone": { + "type": "string", + "description": "The phone number of the subscriber." + }, + "avatar": { + "type": "string", + "description": "The URL of the subscriber's avatar image." + }, + "locale": { + "type": "string", + "description": "The locale setting of the subscriber, indicating their preferred language or region." + }, + "channels": { + "description": "An array of channel settings associated with the subscriber.", + "type": "array", + "items": { + "$ref": "#/components/schemas/ChannelSettingsDto" + } + }, + "topics": { + "description": "An array of topics that the subscriber is subscribed to.", + "deprecated": true, + "type": "array", + "items": { + "type": "string" + } + }, + "isOnline": { + "type": "boolean", + "description": "Indicates whether the subscriber is currently online." + }, + "lastOnlineAt": { + "type": "string", + "description": "The timestamp indicating when the subscriber was last online, in ISO 8601 format." + }, + "__v": { + "type": "number", + "description": "The version of the subscriber document." + }, + "data": { + "type": "object", + "description": "Additional custom data for the subscriber", + "additionalProperties": true, + "nullable": true + }, + "timezone": { + "type": "string", + "description": "Timezone of the subscriber" + } + } + }, + "PreviewPayloadDto": { + "type": "object", + "properties": { + "subscriber": { + "description": "Partial subscriber information", + "allOf": [ + { + "$ref": "#/components/schemas/SubscriberResponseDtoOptional" + } + ] + }, + "payload": { + "type": "object", + "description": "Payload data", + "additionalProperties": true + }, + "steps": { + "type": "object", + "description": "Steps data", + "additionalProperties": true + } + } + }, + "GeneratePreviewResponseDto": { + "type": "object", + "properties": { + "previewPayloadExample": { + "description": "Preview payload example", + "allOf": [ + { + "$ref": "#/components/schemas/PreviewPayloadDto" + } + ] + }, + "result": { + "description": "Preview result", + "oneOf": [ + { + "type": "object", + "additionalProperties": true + }, + { + "properties": { + "type": { + "enum": [ + "email" + ] + }, + "preview": { + "$ref": "#/components/schemas/EmailRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "email" + ] + }, + "preview": { + "$ref": "#/components/schemas/EmailRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "in_app" + ] + }, + "preview": { + "$ref": "#/components/schemas/InAppRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "sms" + ] + }, + "preview": { + "$ref": "#/components/schemas/SmsRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "push" + ] + }, + "preview": { + "$ref": "#/components/schemas/PushRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "chat" + ] + }, + "preview": { + "$ref": "#/components/schemas/ChatRenderOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "delay" + ] + }, + "preview": { + "$ref": "#/components/schemas/DigestRegularOutput" + } + } + }, + { + "properties": { + "type": { + "enum": [ + "digest" + ] + }, + "preview": { + "$ref": "#/components/schemas/DigestRegularOutput" + } + } + } + ] + } + }, + "required": [ + "previewPayloadExample", + "result" + ] + }, + "GeneratePreviewRequestDto": { + "type": "object", + "properties": { + "controlValues": { + "type": "object", + "description": "Optional control values", + "additionalProperties": true + }, + "previewPayload": { + "description": "Optional payload for preview generation", + "allOf": [ + { + "$ref": "#/components/schemas/PreviewPayloadDto" + } + ] + } + } + }, + "PatchWorkflowDto": { + "type": "object", + "properties": { + "active": { + "type": "boolean", + "description": "Activate or deactivate the workflow" + }, + "name": { + "type": "string", + "description": "New name for the workflow" + }, + "description": { + "type": "string", + "description": "Updated description of the workflow" + }, + "tags": { + "type": "array", + "description": "Tags associated with the workflow", + "items": { + "type": "string" + } + } + } + }, + "WorkflowTestDataResponseDto": { + "type": "object", + "properties": { + "to": { + "description": "JSON Schema for recipient data", + "allOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + }, + "payload": { + "description": "JSON Schema for payload data", + "allOf": [ + { + "$ref": "#/components/schemas/JSONSchemaDto" + } + ] + } + }, + "required": [ + "to", + "payload" + ] } }, "headers": { diff --git a/src/lib/config.ts b/src/lib/config.ts index 936c6126..14617a34 100644 --- a/src/lib/config.ts +++ b/src/lib/config.ts @@ -54,8 +54,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null { export const SDK_METADATA = { language: "typescript", - openapiDocVersion: "1.0", - sdkVersion: "0.6.2", - genVersion: "2.563.1", - userAgent: "speakeasy-sdk/typescript 0.6.2 2.563.1 1.0 @novu/api", + openapiDocVersion: "2.1.13", + sdkVersion: "0.7.0", + genVersion: "2.597.9", + userAgent: "speakeasy-sdk/typescript 0.7.0 2.597.9 2.1.13 @novu/api", } as const; diff --git a/src/lib/matchers.ts b/src/lib/matchers.ts index 19b46b33..28c464f4 100644 --- a/src/lib/matchers.ts +++ b/src/lib/matchers.ts @@ -10,6 +10,7 @@ import { isPlainObject } from "./is-plain-object.js"; import { safeParse } from "./schemas.js"; export type Encoding = + | "jsonl" | "json" | "text" | "bytes" @@ -19,6 +20,7 @@ export type Encoding = | "fail"; const DEFAULT_CONTENT_TYPES: Record = { + jsonl: "application/jsonl", json: "application/json", text: "text/plain", bytes: "application/octet-stream", @@ -72,6 +74,21 @@ export function json( return { ...options, enc: "json", codes, schema }; } +export function jsonl( + codes: StatusCodePredicate, + schema: Schema, + options?: MatchOptions, +): ValueMatcher { + return { ...options, enc: "jsonl", codes, schema }; +} + +export function jsonlErr( + codes: StatusCodePredicate, + schema: Schema, + options?: MatchOptions, +): ErrorMatcher { + return { ...options, err: true, enc: "jsonl", codes, schema }; +} export function textErr( codes: StatusCodePredicate, schema: Schema, @@ -204,6 +221,9 @@ export function match( case "json": raw = await response.json(); break; + case "jsonl": + raw = response.body; + break; case "bytes": raw = new Uint8Array(await response.arrayBuffer()); break; diff --git a/src/lib/sdks.ts b/src/lib/sdks.ts index 0b0f2d63..898802de 100644 --- a/src/lib/sdks.ts +++ b/src/lib/sdks.ts @@ -46,12 +46,14 @@ export type RequestOptions = { */ serverURL?: string | URL; /** + * @deprecated `fetchOptions` has been flattened into `RequestOptions`. + * * Sets various request options on the `fetch` call made by an SDK method. * * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options|Request} */ fetchOptions?: Omit; -}; +} & Omit; type RequestConfig = { method: string; @@ -168,7 +170,9 @@ export class ClientSDK { cookie = cookie.startsWith("; ") ? cookie.slice(2) : cookie; headers.set("cookie", cookie); - const userHeaders = new Headers(options?.fetchOptions?.headers); + const userHeaders = new Headers( + options?.headers ?? options?.fetchOptions?.headers, + ); for (const [k, v] of userHeaders) { headers.set(k, v); } @@ -179,20 +183,16 @@ export class ClientSDK { headers.set(conf.uaHeader ?? "user-agent", SDK_METADATA.userAgent); } - let fetchOptions = options?.fetchOptions; + const fetchOptions: Omit = { + ...options?.fetchOptions, + ...options, + }; if (!fetchOptions?.signal && conf.timeoutMs && conf.timeoutMs > 0) { const timeoutSignal = AbortSignal.timeout(conf.timeoutMs); - if (!fetchOptions) { - fetchOptions = { signal: timeoutSignal }; - } else { - fetchOptions.signal = timeoutSignal; - } + fetchOptions.signal = timeoutSignal; } if (conf.body instanceof ReadableStream) { - if (!fetchOptions) { - fetchOptions = {}; - } Object.assign(fetchOptions, { duplex: "half" }); } @@ -298,7 +298,9 @@ export class ClientSDK { } } -const jsonLikeContentTypeRE = /^application\/(?:.{0,100}\+)?json/; +const jsonLikeContentTypeRE = /(application|text)\/.*?\+*json.*/; +const jsonlLikeContentTypeRE = + /(application|text)\/(.*?\+*\bjsonl\b.*|.*?\+*\bx-ndjson\b.*)/; async function logRequest(logger: Logger | undefined, req: Request) { if (!logger) { return; @@ -364,9 +366,13 @@ async function logResponse( logger.group("Body:"); switch (true) { case matchContentType(res, "application/json") - || jsonLikeContentTypeRE.test(ct): + || jsonLikeContentTypeRE.test(ct) && !jsonlLikeContentTypeRE.test(ct): logger.log(await res.clone().json()); break; + case matchContentType(res, "application/jsonl") + || jsonlLikeContentTypeRE.test(ct): + logger.log(await res.clone().text()); + break; case matchContentType(res, "text/event-stream"): logger.log(`<${contentType}>`); break; diff --git a/src/mcp-server/mcp-server.ts b/src/mcp-server/mcp-server.ts index d250a25f..0ffdff16 100644 --- a/src/mcp-server/mcp-server.ts +++ b/src/mcp-server/mcp-server.ts @@ -19,7 +19,7 @@ const routes = buildRouteMap({ export const app = buildApplication(routes, { name: "mcp", versionInfo: { - currentVersion: "0.6.2", + currentVersion: "0.7.0", }, }); diff --git a/src/mcp-server/prompts.ts b/src/mcp-server/prompts.ts index 9f29021f..7ada5998 100644 --- a/src/mcp-server/prompts.ts +++ b/src/mcp-server/prompts.ts @@ -74,7 +74,14 @@ export function createRegisterPrompt( prompt: PromptDefinition, ): void => { const scopes = prompt.scopes ?? []; - if (!scopes.every((s: MCPScope) => allowedScopes.has(s))) { + if (allowedScopes.size > 0 && scopes.length === 0) { + return; + } + + if ( + allowedScopes.size > 0 + && !scopes.every((s: MCPScope) => allowedScopes.has(s)) + ) { return; } diff --git a/src/mcp-server/resources.ts b/src/mcp-server/resources.ts index 1d42fb2b..77abc1a9 100644 --- a/src/mcp-server/resources.ts +++ b/src/mcp-server/resources.ts @@ -109,7 +109,14 @@ export function createRegisterResource( ): (resource: ResourceDefinition) => void { return (resource: ResourceDefinition): void => { const scopes = resource.scopes ?? []; - if (!scopes.every((s: MCPScope) => allowedScopes.has(s))) { + if (allowedScopes.size > 0 && scopes.length === 0) { + return; + } + + if ( + allowedScopes.size > 0 + && !scopes.every((s: MCPScope) => allowedScopes.has(s)) + ) { return; } @@ -137,7 +144,14 @@ export function createRegisterResourceTemplate( ): (resource: ResourceTemplateDefinition) => void { return (resource: ResourceTemplateDefinition): void => { const scopes = resource.scopes ?? []; - if (!scopes.every((s: MCPScope) => allowedScopes.has(s))) { + if (allowedScopes.size > 0 && scopes.length === 0) { + return; + } + + if ( + allowedScopes.size > 0 + && !scopes.every((s: MCPScope) => allowedScopes.has(s)) + ) { return; } diff --git a/src/mcp-server/server.ts b/src/mcp-server/server.ts index a75c11d9..9501ec75 100644 --- a/src/mcp-server/server.ts +++ b/src/mcp-server/server.ts @@ -11,7 +11,7 @@ import { createRegisterResource, createRegisterResourceTemplate, } from "./resources.js"; -import { MCPScope, mcpScopes } from "./scopes.js"; +import { MCPScope } from "./scopes.js"; import { createRegisterTool } from "./tools.js"; import { tool$cancel } from "./tools/cancel.js"; import { tool$integrationsCreate } from "./tools/integrationsCreate.js"; @@ -71,7 +71,7 @@ export function createMCPServer(deps: { }) { const server = new McpServer({ name: "Novu", - version: "0.6.2", + version: "0.7.0", }); const client = new NovuCore({ @@ -80,7 +80,7 @@ export function createMCPServer(deps: { serverIdx: deps.serverIdx, }); - const scopes = new Set(deps.scopes ?? mcpScopes); + const scopes = new Set(deps.scopes); const allowedTools = deps.allowedTools && new Set(deps.allowedTools); const tool = createRegisterTool( diff --git a/src/mcp-server/tools.ts b/src/mcp-server/tools.ts index e9031d66..1b283cb0 100644 --- a/src/mcp-server/tools.ts +++ b/src/mcp-server/tools.ts @@ -102,12 +102,15 @@ export function createRegisterTool( return; } - const toolScopes = tool.scopes ?? []; - if (allowedScopes.size > 0 && toolScopes.length === 0) { + const scopes = tool.scopes ?? []; + if (allowedScopes.size > 0 && scopes.length === 0) { return; } - if (!toolScopes.every((s) => allowedScopes.has(s))) { + if ( + allowedScopes.size > 0 + && !scopes.every((s: MCPScope) => allowedScopes.has(s)) + ) { return; } diff --git a/src/models/components/activitynotificationjobresponsedto.ts b/src/models/components/activitynotificationjobresponsedto.ts index b6bfb10b..f1f97556 100644 --- a/src/models/components/activitynotificationjobresponsedto.ts +++ b/src/models/components/activitynotificationjobresponsedto.ts @@ -56,7 +56,7 @@ export type ActivityNotificationJobResponseDtoType = ClosedEnum< /** * Optional payload for the job */ -export type Payload = {}; +export type ActivityNotificationJobResponseDtoPayload = {}; export type ActivityNotificationJobResponseDto = { /** @@ -86,7 +86,7 @@ export type ActivityNotificationJobResponseDto = { /** * Optional payload for the job */ - payload?: Payload | undefined; + payload?: ActivityNotificationJobResponseDtoPayload | undefined; /** * Provider ID of the job */ @@ -126,43 +126,62 @@ export namespace ActivityNotificationJobResponseDtoType$ { } /** @internal */ -export const Payload$inboundSchema: z.ZodType = - z.object({}); +export const ActivityNotificationJobResponseDtoPayload$inboundSchema: z.ZodType< + ActivityNotificationJobResponseDtoPayload, + z.ZodTypeDef, + unknown +> = z.object({}); /** @internal */ -export type Payload$Outbound = {}; +export type ActivityNotificationJobResponseDtoPayload$Outbound = {}; /** @internal */ -export const Payload$outboundSchema: z.ZodType< - Payload$Outbound, - z.ZodTypeDef, - Payload -> = z.object({}); +export const ActivityNotificationJobResponseDtoPayload$outboundSchema: + z.ZodType< + ActivityNotificationJobResponseDtoPayload$Outbound, + z.ZodTypeDef, + ActivityNotificationJobResponseDtoPayload + > = z.object({}); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Payload$ { - /** @deprecated use `Payload$inboundSchema` instead. */ - export const inboundSchema = Payload$inboundSchema; - /** @deprecated use `Payload$outboundSchema` instead. */ - export const outboundSchema = Payload$outboundSchema; - /** @deprecated use `Payload$Outbound` instead. */ - export type Outbound = Payload$Outbound; +export namespace ActivityNotificationJobResponseDtoPayload$ { + /** @deprecated use `ActivityNotificationJobResponseDtoPayload$inboundSchema` instead. */ + export const inboundSchema = + ActivityNotificationJobResponseDtoPayload$inboundSchema; + /** @deprecated use `ActivityNotificationJobResponseDtoPayload$outboundSchema` instead. */ + export const outboundSchema = + ActivityNotificationJobResponseDtoPayload$outboundSchema; + /** @deprecated use `ActivityNotificationJobResponseDtoPayload$Outbound` instead. */ + export type Outbound = ActivityNotificationJobResponseDtoPayload$Outbound; } -export function payloadToJSON(payload: Payload): string { - return JSON.stringify(Payload$outboundSchema.parse(payload)); +export function activityNotificationJobResponseDtoPayloadToJSON( + activityNotificationJobResponseDtoPayload: + ActivityNotificationJobResponseDtoPayload, +): string { + return JSON.stringify( + ActivityNotificationJobResponseDtoPayload$outboundSchema.parse( + activityNotificationJobResponseDtoPayload, + ), + ); } -export function payloadFromJSON( +export function activityNotificationJobResponseDtoPayloadFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult< + ActivityNotificationJobResponseDtoPayload, + SDKValidationError +> { return safeParse( jsonString, - (x) => Payload$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'Payload' from JSON`, + (x) => + ActivityNotificationJobResponseDtoPayload$inboundSchema.parse( + JSON.parse(x), + ), + `Failed to parse 'ActivityNotificationJobResponseDtoPayload' from JSON`, ); } @@ -180,7 +199,8 @@ export const ActivityNotificationJobResponseDto$inboundSchema: z.ZodType< ), step: ActivityNotificationStepResponseDto$inboundSchema, overrides: z.record(z.any()).optional(), - payload: z.lazy(() => Payload$inboundSchema).optional(), + payload: z.lazy(() => ActivityNotificationJobResponseDtoPayload$inboundSchema) + .optional(), providerId: ProvidersIdEnum$inboundSchema, status: z.string(), updatedAt: z.string().optional(), @@ -200,7 +220,7 @@ export type ActivityNotificationJobResponseDto$Outbound = { >; step: ActivityNotificationStepResponseDto$Outbound; overrides?: { [k: string]: any } | undefined; - payload?: Payload$Outbound | undefined; + payload?: ActivityNotificationJobResponseDtoPayload$Outbound | undefined; providerId: string; status: string; updatedAt?: string | undefined; @@ -220,7 +240,9 @@ export const ActivityNotificationJobResponseDto$outboundSchema: z.ZodType< ), step: ActivityNotificationStepResponseDto$outboundSchema, overrides: z.record(z.any()).optional(), - payload: z.lazy(() => Payload$outboundSchema).optional(), + payload: z.lazy(() => + ActivityNotificationJobResponseDtoPayload$outboundSchema + ).optional(), providerId: ProvidersIdEnum$outboundSchema, status: z.string(), updatedAt: z.string().optional(), diff --git a/src/models/components/activitynotificationstepresponsedto.ts b/src/models/components/activitynotificationstepresponsedto.ts index 799ce38e..370cf5ed 100644 --- a/src/models/components/activitynotificationstepresponsedto.ts +++ b/src/models/components/activitynotificationstepresponsedto.ts @@ -33,7 +33,7 @@ export type ControlVariables = {}; /** * Metadata for the workflow step */ -export type Metadata = {}; +export type ActivityNotificationStepResponseDtoMetadata = {}; /** * Step issues @@ -60,7 +60,7 @@ export type ActivityNotificationStepResponseDto = { /** * Metadata for the workflow step */ - metadata?: Metadata | undefined; + metadata?: ActivityNotificationStepResponseDtoMetadata | undefined; /** * Step issues */ @@ -202,46 +202,63 @@ export function controlVariablesFromJSON( } /** @internal */ -export const Metadata$inboundSchema: z.ZodType< - Metadata, - z.ZodTypeDef, - unknown -> = z.object({}); +export const ActivityNotificationStepResponseDtoMetadata$inboundSchema: + z.ZodType< + ActivityNotificationStepResponseDtoMetadata, + z.ZodTypeDef, + unknown + > = z.object({}); /** @internal */ -export type Metadata$Outbound = {}; +export type ActivityNotificationStepResponseDtoMetadata$Outbound = {}; /** @internal */ -export const Metadata$outboundSchema: z.ZodType< - Metadata$Outbound, - z.ZodTypeDef, - Metadata -> = z.object({}); +export const ActivityNotificationStepResponseDtoMetadata$outboundSchema: + z.ZodType< + ActivityNotificationStepResponseDtoMetadata$Outbound, + z.ZodTypeDef, + ActivityNotificationStepResponseDtoMetadata + > = z.object({}); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Metadata$ { - /** @deprecated use `Metadata$inboundSchema` instead. */ - export const inboundSchema = Metadata$inboundSchema; - /** @deprecated use `Metadata$outboundSchema` instead. */ - export const outboundSchema = Metadata$outboundSchema; - /** @deprecated use `Metadata$Outbound` instead. */ - export type Outbound = Metadata$Outbound; +export namespace ActivityNotificationStepResponseDtoMetadata$ { + /** @deprecated use `ActivityNotificationStepResponseDtoMetadata$inboundSchema` instead. */ + export const inboundSchema = + ActivityNotificationStepResponseDtoMetadata$inboundSchema; + /** @deprecated use `ActivityNotificationStepResponseDtoMetadata$outboundSchema` instead. */ + export const outboundSchema = + ActivityNotificationStepResponseDtoMetadata$outboundSchema; + /** @deprecated use `ActivityNotificationStepResponseDtoMetadata$Outbound` instead. */ + export type Outbound = ActivityNotificationStepResponseDtoMetadata$Outbound; } -export function metadataToJSON(metadata: Metadata): string { - return JSON.stringify(Metadata$outboundSchema.parse(metadata)); +export function activityNotificationStepResponseDtoMetadataToJSON( + activityNotificationStepResponseDtoMetadata: + ActivityNotificationStepResponseDtoMetadata, +): string { + return JSON.stringify( + ActivityNotificationStepResponseDtoMetadata$outboundSchema.parse( + activityNotificationStepResponseDtoMetadata, + ), + ); } -export function metadataFromJSON( +export function activityNotificationStepResponseDtoMetadataFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult< + ActivityNotificationStepResponseDtoMetadata, + SDKValidationError +> { return safeParse( jsonString, - (x) => Metadata$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'Metadata' from JSON`, + (x) => + ActivityNotificationStepResponseDtoMetadata$inboundSchema.parse( + JSON.parse(x), + ), + `Failed to parse 'ActivityNotificationStepResponseDtoMetadata' from JSON`, ); } @@ -298,7 +315,9 @@ export const ActivityNotificationStepResponseDto$inboundSchema: z.ZodType< ActivityNotificationStepResponseDtoReplyCallback$inboundSchema ).optional(), controlVariables: z.lazy(() => ControlVariables$inboundSchema).optional(), - metadata: z.lazy(() => Metadata$inboundSchema).optional(), + metadata: z.lazy(() => + ActivityNotificationStepResponseDtoMetadata$inboundSchema + ).optional(), issues: z.lazy(() => Issues$inboundSchema).optional(), filters: z.array(StepFilterDto$inboundSchema), template: MessageTemplateDto$inboundSchema.optional(), @@ -324,7 +343,7 @@ export type ActivityNotificationStepResponseDto$Outbound = { | ActivityNotificationStepResponseDtoReplyCallback$Outbound | undefined; controlVariables?: ControlVariables$Outbound | undefined; - metadata?: Metadata$Outbound | undefined; + metadata?: ActivityNotificationStepResponseDtoMetadata$Outbound | undefined; issues?: Issues$Outbound | undefined; filters: Array; template?: MessageTemplateDto$Outbound | undefined; @@ -346,7 +365,9 @@ export const ActivityNotificationStepResponseDto$outboundSchema: z.ZodType< ActivityNotificationStepResponseDtoReplyCallback$outboundSchema ).optional(), controlVariables: z.lazy(() => ControlVariables$outboundSchema).optional(), - metadata: z.lazy(() => Metadata$outboundSchema).optional(), + metadata: z.lazy(() => + ActivityNotificationStepResponseDtoMetadata$outboundSchema + ).optional(), issues: z.lazy(() => Issues$outboundSchema).optional(), filters: z.array(StepFilterDto$outboundSchema), template: MessageTemplateDto$outboundSchema.optional(), diff --git a/src/models/components/channelsettingsdto.ts b/src/models/components/channelsettingsdto.ts index 646f8f69..94106ae9 100644 --- a/src/models/components/channelsettingsdto.ts +++ b/src/models/components/channelsettingsdto.ts @@ -5,7 +5,6 @@ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; -import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { @@ -14,39 +13,17 @@ import { ChannelCredentials$Outbound, ChannelCredentials$outboundSchema, } from "./channelcredentials.js"; - -/** - * The provider identifier for the credentials - */ -export const ProviderId = { - Slack: "slack", - Discord: "discord", - Msteams: "msteams", - Mattermost: "mattermost", - Ryver: "ryver", - Zulip: "zulip", - GrafanaOnCall: "grafana-on-call", - Getstream: "getstream", - RocketChat: "rocket-chat", - WhatsappBusiness: "whatsapp-business", - Fcm: "fcm", - Apns: "apns", - Expo: "expo", - OneSignal: "one-signal", - Pushpad: "pushpad", - PushWebhook: "push-webhook", - PusherBeams: "pusher-beams", -} as const; -/** - * The provider identifier for the credentials - */ -export type ProviderId = ClosedEnum; +import { + ChatOrPushProviderEnum, + ChatOrPushProviderEnum$inboundSchema, + ChatOrPushProviderEnum$outboundSchema, +} from "./chatorpushproviderenum.js"; export type ChannelSettingsDto = { /** * The provider identifier for the credentials */ - providerId: ProviderId; + providerId: ChatOrPushProviderEnum; /** * The integration identifier */ @@ -61,32 +38,13 @@ export type ChannelSettingsDto = { integrationId: string; }; -/** @internal */ -export const ProviderId$inboundSchema: z.ZodNativeEnum = z - .nativeEnum(ProviderId); - -/** @internal */ -export const ProviderId$outboundSchema: z.ZodNativeEnum = - ProviderId$inboundSchema; - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace ProviderId$ { - /** @deprecated use `ProviderId$inboundSchema` instead. */ - export const inboundSchema = ProviderId$inboundSchema; - /** @deprecated use `ProviderId$outboundSchema` instead. */ - export const outboundSchema = ProviderId$outboundSchema; -} - /** @internal */ export const ChannelSettingsDto$inboundSchema: z.ZodType< ChannelSettingsDto, z.ZodTypeDef, unknown > = z.object({ - providerId: ProviderId$inboundSchema, + providerId: ChatOrPushProviderEnum$inboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentials$inboundSchema, _integrationId: z.string(), @@ -110,7 +68,7 @@ export const ChannelSettingsDto$outboundSchema: z.ZodType< z.ZodTypeDef, ChannelSettingsDto > = z.object({ - providerId: ProviderId$outboundSchema, + providerId: ChatOrPushProviderEnum$outboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentials$outboundSchema, integrationId: z.string(), diff --git a/src/models/components/chatorpushproviderenum.ts b/src/models/components/chatorpushproviderenum.ts new file mode 100644 index 00000000..0bfaf2f9 --- /dev/null +++ b/src/models/components/chatorpushproviderenum.ts @@ -0,0 +1,54 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { ClosedEnum } from "../../types/enums.js"; + +/** + * The provider identifier for the credentials + */ +export const ChatOrPushProviderEnum = { + Slack: "slack", + Discord: "discord", + Msteams: "msteams", + Mattermost: "mattermost", + Ryver: "ryver", + Zulip: "zulip", + GrafanaOnCall: "grafana-on-call", + Getstream: "getstream", + RocketChat: "rocket-chat", + WhatsappBusiness: "whatsapp-business", + Fcm: "fcm", + Apns: "apns", + Expo: "expo", + OneSignal: "one-signal", + Pushpad: "pushpad", + PushWebhook: "push-webhook", + PusherBeams: "pusher-beams", +} as const; +/** + * The provider identifier for the credentials + */ +export type ChatOrPushProviderEnum = ClosedEnum; + +/** @internal */ +export const ChatOrPushProviderEnum$inboundSchema: z.ZodNativeEnum< + typeof ChatOrPushProviderEnum +> = z.nativeEnum(ChatOrPushProviderEnum); + +/** @internal */ +export const ChatOrPushProviderEnum$outboundSchema: z.ZodNativeEnum< + typeof ChatOrPushProviderEnum +> = ChatOrPushProviderEnum$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ChatOrPushProviderEnum$ { + /** @deprecated use `ChatOrPushProviderEnum$inboundSchema` instead. */ + export const inboundSchema = ChatOrPushProviderEnum$inboundSchema; + /** @deprecated use `ChatOrPushProviderEnum$outboundSchema` instead. */ + export const outboundSchema = ChatOrPushProviderEnum$outboundSchema; +} diff --git a/src/models/components/constraintvalidation.ts b/src/models/components/constraintvalidation.ts new file mode 100644 index 00000000..bdf3475a --- /dev/null +++ b/src/models/components/constraintvalidation.ts @@ -0,0 +1,270 @@ +/* + * 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 Five = string | number | boolean | { [k: string]: any }; + +export type Four = {}; + +/** + * Value that failed validation + */ +export type Value = + | Four + | string + | number + | boolean + | Array; + +export type ConstraintValidation = { + /** + * List of validation error messages + */ + messages: Array; + /** + * Value that failed validation + */ + value?: + | Four + | string + | number + | boolean + | Array + | null + | undefined; +}; + +/** @internal */ +export const Five$inboundSchema: z.ZodType = z + .union([z.string(), z.number(), z.boolean(), z.record(z.any())]); + +/** @internal */ +export type Five$Outbound = string | number | boolean | { [k: string]: any }; + +/** @internal */ +export const Five$outboundSchema: z.ZodType = + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Five$ { + /** @deprecated use `Five$inboundSchema` instead. */ + export const inboundSchema = Five$inboundSchema; + /** @deprecated use `Five$outboundSchema` instead. */ + export const outboundSchema = Five$outboundSchema; + /** @deprecated use `Five$Outbound` instead. */ + export type Outbound = Five$Outbound; +} + +export function fiveToJSON(five: Five): string { + return JSON.stringify(Five$outboundSchema.parse(five)); +} + +export function fiveFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Five$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Five' from JSON`, + ); +} + +/** @internal */ +export const Four$inboundSchema: z.ZodType = z + .object({}); + +/** @internal */ +export type Four$Outbound = {}; + +/** @internal */ +export const Four$outboundSchema: z.ZodType = + z.object({}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Four$ { + /** @deprecated use `Four$inboundSchema` instead. */ + export const inboundSchema = Four$inboundSchema; + /** @deprecated use `Four$outboundSchema` instead. */ + export const outboundSchema = Four$outboundSchema; + /** @deprecated use `Four$Outbound` instead. */ + export type Outbound = Four$Outbound; +} + +export function fourToJSON(four: Four): string { + return JSON.stringify(Four$outboundSchema.parse(four)); +} + +export function fourFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Four$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Four' from JSON`, + ); +} + +/** @internal */ +export const Value$inboundSchema: z.ZodType = z + .union([ + z.lazy(() => Four$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]); + +/** @internal */ +export type Value$Outbound = + | Four$Outbound + | string + | number + | boolean + | Array; + +/** @internal */ +export const Value$outboundSchema: z.ZodType< + Value$Outbound, + z.ZodTypeDef, + Value +> = z.union([ + z.lazy(() => Four$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), +]); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Value$ { + /** @deprecated use `Value$inboundSchema` instead. */ + export const inboundSchema = Value$inboundSchema; + /** @deprecated use `Value$outboundSchema` instead. */ + export const outboundSchema = Value$outboundSchema; + /** @deprecated use `Value$Outbound` instead. */ + export type Outbound = Value$Outbound; +} + +export function valueToJSON(value: Value): string { + return JSON.stringify(Value$outboundSchema.parse(value)); +} + +export function valueFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Value$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Value' from JSON`, + ); +} + +/** @internal */ +export const ConstraintValidation$inboundSchema: z.ZodType< + ConstraintValidation, + z.ZodTypeDef, + unknown +> = z.object({ + messages: z.array(z.string()), + value: z.nullable( + z.union([ + z.lazy(() => Four$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), +}); + +/** @internal */ +export type ConstraintValidation$Outbound = { + messages: Array; + value?: + | Four$Outbound + | string + | number + | boolean + | Array + | null + | undefined; +}; + +/** @internal */ +export const ConstraintValidation$outboundSchema: z.ZodType< + ConstraintValidation$Outbound, + z.ZodTypeDef, + ConstraintValidation +> = z.object({ + messages: z.array(z.string()), + value: z.nullable( + z.union([ + z.lazy(() => Four$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace ConstraintValidation$ { + /** @deprecated use `ConstraintValidation$inboundSchema` instead. */ + export const inboundSchema = ConstraintValidation$inboundSchema; + /** @deprecated use `ConstraintValidation$outboundSchema` instead. */ + export const outboundSchema = ConstraintValidation$outboundSchema; + /** @deprecated use `ConstraintValidation$Outbound` instead. */ + export type Outbound = ConstraintValidation$Outbound; +} + +export function constraintValidationToJSON( + constraintValidation: ConstraintValidation, +): string { + return JSON.stringify( + ConstraintValidation$outboundSchema.parse(constraintValidation), + ); +} + +export function constraintValidationFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => ConstraintValidation$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'ConstraintValidation' from JSON`, + ); +} diff --git a/src/models/components/digestmetadatadto.ts b/src/models/components/digestmetadatadto.ts index b8f62c3f..f5f7d922 100644 --- a/src/models/components/digestmetadatadto.ts +++ b/src/models/components/digestmetadatadto.ts @@ -27,7 +27,7 @@ import { /** * Unit of the digest */ -export const Unit = { +export const DigestMetadataDtoUnit = { Seconds: "seconds", Minutes: "minutes", Hours: "hours", @@ -38,7 +38,7 @@ export const Unit = { /** * Unit of the digest */ -export type Unit = ClosedEnum; +export type DigestMetadataDtoUnit = ClosedEnum; export type DigestMetadataDto = { /** @@ -52,7 +52,7 @@ export type DigestMetadataDto = { /** * Unit of the digest */ - unit?: Unit | undefined; + unit?: DigestMetadataDtoUnit | undefined; /** * The Digest Type */ @@ -84,23 +84,24 @@ export type DigestMetadataDto = { }; /** @internal */ -export const Unit$inboundSchema: z.ZodNativeEnum = z.nativeEnum( - Unit, -); +export const DigestMetadataDtoUnit$inboundSchema: z.ZodNativeEnum< + typeof DigestMetadataDtoUnit +> = z.nativeEnum(DigestMetadataDtoUnit); /** @internal */ -export const Unit$outboundSchema: z.ZodNativeEnum = - Unit$inboundSchema; +export const DigestMetadataDtoUnit$outboundSchema: z.ZodNativeEnum< + typeof DigestMetadataDtoUnit +> = DigestMetadataDtoUnit$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Unit$ { - /** @deprecated use `Unit$inboundSchema` instead. */ - export const inboundSchema = Unit$inboundSchema; - /** @deprecated use `Unit$outboundSchema` instead. */ - export const outboundSchema = Unit$outboundSchema; +export namespace DigestMetadataDtoUnit$ { + /** @deprecated use `DigestMetadataDtoUnit$inboundSchema` instead. */ + export const inboundSchema = DigestMetadataDtoUnit$inboundSchema; + /** @deprecated use `DigestMetadataDtoUnit$outboundSchema` instead. */ + export const outboundSchema = DigestMetadataDtoUnit$outboundSchema; } /** @internal */ @@ -111,7 +112,7 @@ export const DigestMetadataDto$inboundSchema: z.ZodType< > = z.object({ digestKey: z.string().optional(), amount: z.number().optional(), - unit: Unit$inboundSchema.optional(), + unit: DigestMetadataDtoUnit$inboundSchema.optional(), type: DigestTypeEnum$inboundSchema, events: z.array(z.record(z.any())).optional(), backoff: z.boolean().optional(), @@ -143,7 +144,7 @@ export const DigestMetadataDto$outboundSchema: z.ZodType< > = z.object({ digestKey: z.string().optional(), amount: z.number().optional(), - unit: Unit$outboundSchema.optional(), + unit: DigestMetadataDtoUnit$outboundSchema.optional(), type: DigestTypeEnum$outboundSchema, events: z.array(z.record(z.any())).optional(), backoff: z.boolean().optional(), diff --git a/src/models/components/digestregularmetadata.ts b/src/models/components/digestregularmetadata.ts index 708fb374..707dd7d6 100644 --- a/src/models/components/digestregularmetadata.ts +++ b/src/models/components/digestregularmetadata.ts @@ -8,7 +8,7 @@ import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; -export const DigestRegularMetadataUnit = { +export const Unit = { Seconds: "seconds", Minutes: "minutes", Hours: "hours", @@ -16,17 +16,13 @@ export const DigestRegularMetadataUnit = { Weeks: "weeks", Months: "months", } as const; -export type DigestRegularMetadataUnit = ClosedEnum< - typeof DigestRegularMetadataUnit ->; +export type Unit = ClosedEnum; -export const DigestRegularMetadataType = { +export const Type = { Regular: "regular", Backoff: "backoff", } as const; -export type DigestRegularMetadataType = ClosedEnum< - typeof DigestRegularMetadataType ->; +export type Type = ClosedEnum; export const BackoffUnit = { Seconds: "seconds", @@ -40,9 +36,9 @@ export type BackoffUnit = ClosedEnum; export type DigestRegularMetadata = { amount?: number | undefined; - unit?: DigestRegularMetadataUnit | undefined; + unit?: Unit | undefined; digestKey?: string | undefined; - type: DigestRegularMetadataType; + type: Type; backoff?: boolean | undefined; backoffAmount?: number | undefined; backoffUnit?: BackoffUnit | undefined; @@ -50,45 +46,43 @@ export type DigestRegularMetadata = { }; /** @internal */ -export const DigestRegularMetadataUnit$inboundSchema: z.ZodNativeEnum< - typeof DigestRegularMetadataUnit -> = z.nativeEnum(DigestRegularMetadataUnit); +export const Unit$inboundSchema: z.ZodNativeEnum = z.nativeEnum( + Unit, +); /** @internal */ -export const DigestRegularMetadataUnit$outboundSchema: z.ZodNativeEnum< - typeof DigestRegularMetadataUnit -> = DigestRegularMetadataUnit$inboundSchema; +export const Unit$outboundSchema: z.ZodNativeEnum = + Unit$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace DigestRegularMetadataUnit$ { - /** @deprecated use `DigestRegularMetadataUnit$inboundSchema` instead. */ - export const inboundSchema = DigestRegularMetadataUnit$inboundSchema; - /** @deprecated use `DigestRegularMetadataUnit$outboundSchema` instead. */ - export const outboundSchema = DigestRegularMetadataUnit$outboundSchema; +export namespace Unit$ { + /** @deprecated use `Unit$inboundSchema` instead. */ + export const inboundSchema = Unit$inboundSchema; + /** @deprecated use `Unit$outboundSchema` instead. */ + export const outboundSchema = Unit$outboundSchema; } /** @internal */ -export const DigestRegularMetadataType$inboundSchema: z.ZodNativeEnum< - typeof DigestRegularMetadataType -> = z.nativeEnum(DigestRegularMetadataType); +export const Type$inboundSchema: z.ZodNativeEnum = z.nativeEnum( + Type, +); /** @internal */ -export const DigestRegularMetadataType$outboundSchema: z.ZodNativeEnum< - typeof DigestRegularMetadataType -> = DigestRegularMetadataType$inboundSchema; +export const Type$outboundSchema: z.ZodNativeEnum = + Type$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace DigestRegularMetadataType$ { - /** @deprecated use `DigestRegularMetadataType$inboundSchema` instead. */ - export const inboundSchema = DigestRegularMetadataType$inboundSchema; - /** @deprecated use `DigestRegularMetadataType$outboundSchema` instead. */ - export const outboundSchema = DigestRegularMetadataType$outboundSchema; +export namespace Type$ { + /** @deprecated use `Type$inboundSchema` instead. */ + export const inboundSchema = Type$inboundSchema; + /** @deprecated use `Type$outboundSchema` instead. */ + export const outboundSchema = Type$outboundSchema; } /** @internal */ @@ -117,9 +111,9 @@ export const DigestRegularMetadata$inboundSchema: z.ZodType< unknown > = z.object({ amount: z.number().optional(), - unit: DigestRegularMetadataUnit$inboundSchema.optional(), + unit: Unit$inboundSchema.optional(), digestKey: z.string().optional(), - type: DigestRegularMetadataType$inboundSchema, + type: Type$inboundSchema, backoff: z.boolean().optional(), backoffAmount: z.number().optional(), backoffUnit: BackoffUnit$inboundSchema.optional(), @@ -145,9 +139,9 @@ export const DigestRegularMetadata$outboundSchema: z.ZodType< DigestRegularMetadata > = z.object({ amount: z.number().optional(), - unit: DigestRegularMetadataUnit$outboundSchema.optional(), + unit: Unit$outboundSchema.optional(), digestKey: z.string().optional(), - type: DigestRegularMetadataType$outboundSchema, + type: Type$outboundSchema, backoff: z.boolean().optional(), backoffAmount: z.number().optional(), backoffUnit: BackoffUnit$outboundSchema.optional(), diff --git a/src/models/components/digesttimedconfigdto.ts b/src/models/components/digesttimedconfigdto.ts index 63e30f1d..058a7db2 100644 --- a/src/models/components/digesttimedconfigdto.ts +++ b/src/models/components/digesttimedconfigdto.ts @@ -23,7 +23,7 @@ import { OrdinalValueEnum$outboundSchema, } from "./ordinalvalueenum.js"; -export const WeekDays = { +export const DigestTimedConfigDtoWeekDays = { Monday: "monday", Tuesday: "tuesday", Wednesday: "wednesday", @@ -32,7 +32,9 @@ export const WeekDays = { Saturday: "saturday", Sunday: "sunday", } as const; -export type WeekDays = ClosedEnum; +export type DigestTimedConfigDtoWeekDays = ClosedEnum< + typeof DigestTimedConfigDtoWeekDays +>; export type DigestTimedConfigDto = { /** @@ -42,7 +44,7 @@ export type DigestTimedConfigDto = { /** * Days of the week for the digest */ - weekDays?: Array | undefined; + weekDays?: Array | undefined; /** * Specific days of the month for the digest */ @@ -66,22 +68,24 @@ export type DigestTimedConfigDto = { }; /** @internal */ -export const WeekDays$inboundSchema: z.ZodNativeEnum = z - .nativeEnum(WeekDays); +export const DigestTimedConfigDtoWeekDays$inboundSchema: z.ZodNativeEnum< + typeof DigestTimedConfigDtoWeekDays +> = z.nativeEnum(DigestTimedConfigDtoWeekDays); /** @internal */ -export const WeekDays$outboundSchema: z.ZodNativeEnum = - WeekDays$inboundSchema; +export const DigestTimedConfigDtoWeekDays$outboundSchema: z.ZodNativeEnum< + typeof DigestTimedConfigDtoWeekDays +> = DigestTimedConfigDtoWeekDays$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace WeekDays$ { - /** @deprecated use `WeekDays$inboundSchema` instead. */ - export const inboundSchema = WeekDays$inboundSchema; - /** @deprecated use `WeekDays$outboundSchema` instead. */ - export const outboundSchema = WeekDays$outboundSchema; +export namespace DigestTimedConfigDtoWeekDays$ { + /** @deprecated use `DigestTimedConfigDtoWeekDays$inboundSchema` instead. */ + export const inboundSchema = DigestTimedConfigDtoWeekDays$inboundSchema; + /** @deprecated use `DigestTimedConfigDtoWeekDays$outboundSchema` instead. */ + export const outboundSchema = DigestTimedConfigDtoWeekDays$outboundSchema; } /** @internal */ @@ -91,7 +95,7 @@ export const DigestTimedConfigDto$inboundSchema: z.ZodType< unknown > = z.object({ atTime: z.string().optional(), - weekDays: z.array(WeekDays$inboundSchema).optional(), + weekDays: z.array(DigestTimedConfigDtoWeekDays$inboundSchema).optional(), monthDays: z.array(z.number()).optional(), ordinal: OrdinalEnum$inboundSchema.optional(), ordinalValue: OrdinalValueEnum$inboundSchema.optional(), @@ -117,7 +121,7 @@ export const DigestTimedConfigDto$outboundSchema: z.ZodType< DigestTimedConfigDto > = z.object({ atTime: z.string().optional(), - weekDays: z.array(WeekDays$outboundSchema).optional(), + weekDays: z.array(DigestTimedConfigDtoWeekDays$outboundSchema).optional(), monthDays: z.array(z.number()).optional(), ordinal: OrdinalEnum$outboundSchema.optional(), ordinalValue: OrdinalValueEnum$outboundSchema.optional(), diff --git a/src/models/components/getsubscriberpreferencesdto.ts b/src/models/components/getsubscriberpreferencesdto.ts index ff12360d..42a6a8cd 100644 --- a/src/models/components/getsubscriberpreferencesdto.ts +++ b/src/models/components/getsubscriberpreferencesdto.ts @@ -7,27 +7,27 @@ import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { - GlobalPreferenceDto, - GlobalPreferenceDto$inboundSchema, - GlobalPreferenceDto$Outbound, - GlobalPreferenceDto$outboundSchema, -} from "./globalpreferencedto.js"; + SubscriberGlobalPreferenceDto, + SubscriberGlobalPreferenceDto$inboundSchema, + SubscriberGlobalPreferenceDto$Outbound, + SubscriberGlobalPreferenceDto$outboundSchema, +} from "./subscriberglobalpreferencedto.js"; import { - WorkflowPreferenceDto, - WorkflowPreferenceDto$inboundSchema, - WorkflowPreferenceDto$Outbound, - WorkflowPreferenceDto$outboundSchema, -} from "./workflowpreferencedto.js"; + SubscriberWorkflowPreferenceDto, + SubscriberWorkflowPreferenceDto$inboundSchema, + SubscriberWorkflowPreferenceDto$Outbound, + SubscriberWorkflowPreferenceDto$outboundSchema, +} from "./subscriberworkflowpreferencedto.js"; export type GetSubscriberPreferencesDto = { /** * Global preference settings */ - global: GlobalPreferenceDto; + global: SubscriberGlobalPreferenceDto; /** * Workflow-specific preference settings */ - workflows: Array; + workflows: Array; }; /** @internal */ @@ -36,14 +36,14 @@ export const GetSubscriberPreferencesDto$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - global: GlobalPreferenceDto$inboundSchema, - workflows: z.array(WorkflowPreferenceDto$inboundSchema), + global: SubscriberGlobalPreferenceDto$inboundSchema, + workflows: z.array(SubscriberWorkflowPreferenceDto$inboundSchema), }); /** @internal */ export type GetSubscriberPreferencesDto$Outbound = { - global: GlobalPreferenceDto$Outbound; - workflows: Array; + global: SubscriberGlobalPreferenceDto$Outbound; + workflows: Array; }; /** @internal */ @@ -52,8 +52,8 @@ export const GetSubscriberPreferencesDto$outboundSchema: z.ZodType< z.ZodTypeDef, GetSubscriberPreferencesDto > = z.object({ - global: GlobalPreferenceDto$outboundSchema, - workflows: z.array(WorkflowPreferenceDto$outboundSchema), + global: SubscriberGlobalPreferenceDto$outboundSchema, + workflows: z.array(SubscriberWorkflowPreferenceDto$outboundSchema), }); /** diff --git a/src/models/components/globalpreferencedto.ts b/src/models/components/globalpreferencedto.ts deleted file mode 100644 index 8bd0306f..00000000 --- a/src/models/components/globalpreferencedto.ts +++ /dev/null @@ -1,82 +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"; -import { - PreferenceChannels, - PreferenceChannels$inboundSchema, - PreferenceChannels$Outbound, - PreferenceChannels$outboundSchema, -} from "./preferencechannels.js"; - -export type GlobalPreferenceDto = { - /** - * Whether notifications are enabled globally - */ - enabled: boolean; - /** - * Channel-specific preference settings - */ - channels: PreferenceChannels; -}; - -/** @internal */ -export const GlobalPreferenceDto$inboundSchema: z.ZodType< - GlobalPreferenceDto, - z.ZodTypeDef, - unknown -> = z.object({ - enabled: z.boolean(), - channels: PreferenceChannels$inboundSchema, -}); - -/** @internal */ -export type GlobalPreferenceDto$Outbound = { - enabled: boolean; - channels: PreferenceChannels$Outbound; -}; - -/** @internal */ -export const GlobalPreferenceDto$outboundSchema: z.ZodType< - GlobalPreferenceDto$Outbound, - z.ZodTypeDef, - GlobalPreferenceDto -> = z.object({ - enabled: z.boolean(), - channels: PreferenceChannels$outboundSchema, -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace GlobalPreferenceDto$ { - /** @deprecated use `GlobalPreferenceDto$inboundSchema` instead. */ - export const inboundSchema = GlobalPreferenceDto$inboundSchema; - /** @deprecated use `GlobalPreferenceDto$outboundSchema` instead. */ - export const outboundSchema = GlobalPreferenceDto$outboundSchema; - /** @deprecated use `GlobalPreferenceDto$Outbound` instead. */ - export type Outbound = GlobalPreferenceDto$Outbound; -} - -export function globalPreferenceDtoToJSON( - globalPreferenceDto: GlobalPreferenceDto, -): string { - return JSON.stringify( - GlobalPreferenceDto$outboundSchema.parse(globalPreferenceDto), - ); -} - -export function globalPreferenceDtoFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => GlobalPreferenceDto$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'GlobalPreferenceDto' from JSON`, - ); -} diff --git a/src/models/components/index.ts b/src/models/components/index.ts index d26dbd43..415de40a 100644 --- a/src/models/components/index.ts +++ b/src/models/components/index.ts @@ -25,6 +25,8 @@ export * from "./channelcredentialsdto.js"; export * from "./channelctatypeenum.js"; export * from "./channelsettingsdto.js"; export * from "./channeltypeenum.js"; +export * from "./chatorpushproviderenum.js"; +export * from "./constraintvalidation.js"; export * from "./createdsubscriberdto.js"; export * from "./createintegrationrequestdto.js"; export * from "./createsubscriberrequestdto.js"; @@ -52,7 +54,6 @@ export * from "./fieldfilterpartdto.js"; export * from "./filtertopicsresponsedto.js"; export * from "./getsubscriberpreferencesdto.js"; export * from "./gettopicresponsedto.js"; -export * from "./globalpreferencedto.js"; export * from "./integrationresponsedto.js"; export * from "./listsubscribersresponsedto.js"; export * from "./markallmessageasrequestdto.js"; @@ -65,6 +66,7 @@ export * from "./messagecta.js"; export * from "./messagectadata.js"; export * from "./messagemarkasrequestdto.js"; export * from "./messageresponsedto.js"; +export * from "./messagesresponsedto.js"; export * from "./messagestatusenum.js"; export * from "./messagetemplate.js"; export * from "./messagetemplatedto.js"; @@ -78,11 +80,10 @@ export * from "./notificationtriggerdto.js"; export * from "./notificationtriggervariable.js"; export * from "./ordinalenum.js"; export * from "./ordinalvalueenum.js"; -export * from "./overrides.js"; export * from "./patchpreferencechannelsdto.js"; export * from "./patchsubscriberpreferencesdto.js"; export * from "./patchsubscriberrequestdto.js"; -export * from "./preferencechannels.js"; +export * from "./preferenceoverridesourceenum.js"; export * from "./providersidenum.js"; export * from "./removesubscriberresponsedto.js"; export * from "./removesubscribersrequestdto.js"; @@ -91,11 +92,17 @@ export * from "./renametopicresponsedto.js"; export * from "./replycallback.js"; export * from "./security.js"; export * from "./stepfilterdto.js"; +export * from "./stepsoverrides.js"; export * from "./steptypeenum.js"; export * from "./subscriberchanneldto.js"; export * from "./subscriberfeedresponsedto.js"; +export * from "./subscriberglobalpreferencedto.js"; export * from "./subscriberpayloaddto.js"; +export * from "./subscriberpreferencechannels.js"; +export * from "./subscriberpreferenceoverridedto.js"; +export * from "./subscriberpreferencesworkflowinfodto.js"; export * from "./subscriberresponsedto.js"; +export * from "./subscriberworkflowpreferencedto.js"; export * from "./tenantpayloaddto.js"; export * from "./textalignenum.js"; export * from "./timedconfig.js"; @@ -112,7 +119,5 @@ export * from "./updateintegrationrequestdto.js"; export * from "./updatesubscriberchannelrequestdto.js"; export * from "./updatesubscriberonlineflagrequestdto.js"; export * from "./updatesubscriberrequestdto.js"; -export * from "./workflowinfodto.js"; export * from "./workfloworiginenum.js"; -export * from "./workflowpreferencedto.js"; export * from "./workflowresponse.js"; diff --git a/src/models/components/integrationresponsedto.ts b/src/models/components/integrationresponsedto.ts index e5b93191..a1424485 100644 --- a/src/models/components/integrationresponsedto.ts +++ b/src/models/components/integrationresponsedto.ts @@ -24,7 +24,7 @@ import { /** * The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). */ -export const IntegrationResponseDtoChannel = { +export const Channel = { InApp: "in_app", Email: "email", Sms: "sms", @@ -34,9 +34,7 @@ export const IntegrationResponseDtoChannel = { /** * The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). */ -export type IntegrationResponseDtoChannel = ClosedEnum< - typeof IntegrationResponseDtoChannel ->; +export type Channel = ClosedEnum; export type IntegrationResponseDto = { /** @@ -66,7 +64,7 @@ export type IntegrationResponseDto = { /** * The channel type for the integration, which defines how the integration communicates (e.g., email, SMS). */ - channel: IntegrationResponseDtoChannel; + channel: Channel; /** * The credentials required for the integration to function, including API keys and other sensitive information. */ @@ -98,24 +96,22 @@ export type IntegrationResponseDto = { }; /** @internal */ -export const IntegrationResponseDtoChannel$inboundSchema: z.ZodNativeEnum< - typeof IntegrationResponseDtoChannel -> = z.nativeEnum(IntegrationResponseDtoChannel); +export const Channel$inboundSchema: z.ZodNativeEnum = z + .nativeEnum(Channel); /** @internal */ -export const IntegrationResponseDtoChannel$outboundSchema: z.ZodNativeEnum< - typeof IntegrationResponseDtoChannel -> = IntegrationResponseDtoChannel$inboundSchema; +export const Channel$outboundSchema: z.ZodNativeEnum = + Channel$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace IntegrationResponseDtoChannel$ { - /** @deprecated use `IntegrationResponseDtoChannel$inboundSchema` instead. */ - export const inboundSchema = IntegrationResponseDtoChannel$inboundSchema; - /** @deprecated use `IntegrationResponseDtoChannel$outboundSchema` instead. */ - export const outboundSchema = IntegrationResponseDtoChannel$outboundSchema; +export namespace Channel$ { + /** @deprecated use `Channel$inboundSchema` instead. */ + export const inboundSchema = Channel$inboundSchema; + /** @deprecated use `Channel$outboundSchema` instead. */ + export const outboundSchema = Channel$outboundSchema; } /** @internal */ @@ -130,7 +126,7 @@ export const IntegrationResponseDto$inboundSchema: z.ZodType< name: z.string(), identifier: z.string(), providerId: z.string(), - channel: IntegrationResponseDtoChannel$inboundSchema, + channel: Channel$inboundSchema, credentials: CredentialsDto$inboundSchema, active: z.boolean(), deleted: z.boolean(), @@ -176,7 +172,7 @@ export const IntegrationResponseDto$outboundSchema: z.ZodType< name: z.string(), identifier: z.string(), providerId: z.string(), - channel: IntegrationResponseDtoChannel$outboundSchema, + channel: Channel$outboundSchema, credentials: CredentialsDto$outboundSchema, active: z.boolean(), deleted: z.boolean(), diff --git a/src/models/components/messageactionresult.ts b/src/models/components/messageactionresult.ts index 257a6592..7ea3ef61 100644 --- a/src/models/components/messageactionresult.ts +++ b/src/models/components/messageactionresult.ts @@ -15,13 +15,13 @@ import { /** * Payload of the action result */ -export type MessageActionResultPayload = {}; +export type Payload = {}; export type MessageActionResult = { /** * Payload of the action result */ - payload?: MessageActionResultPayload | undefined; + payload?: Payload | undefined; /** * Type of button for the action result */ @@ -29,50 +29,43 @@ export type MessageActionResult = { }; /** @internal */ -export const MessageActionResultPayload$inboundSchema: z.ZodType< - MessageActionResultPayload, - z.ZodTypeDef, - unknown -> = z.object({}); +export const Payload$inboundSchema: z.ZodType = + z.object({}); /** @internal */ -export type MessageActionResultPayload$Outbound = {}; +export type Payload$Outbound = {}; /** @internal */ -export const MessageActionResultPayload$outboundSchema: z.ZodType< - MessageActionResultPayload$Outbound, +export const Payload$outboundSchema: z.ZodType< + Payload$Outbound, z.ZodTypeDef, - MessageActionResultPayload + Payload > = z.object({}); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace MessageActionResultPayload$ { - /** @deprecated use `MessageActionResultPayload$inboundSchema` instead. */ - export const inboundSchema = MessageActionResultPayload$inboundSchema; - /** @deprecated use `MessageActionResultPayload$outboundSchema` instead. */ - export const outboundSchema = MessageActionResultPayload$outboundSchema; - /** @deprecated use `MessageActionResultPayload$Outbound` instead. */ - export type Outbound = MessageActionResultPayload$Outbound; +export namespace Payload$ { + /** @deprecated use `Payload$inboundSchema` instead. */ + export const inboundSchema = Payload$inboundSchema; + /** @deprecated use `Payload$outboundSchema` instead. */ + export const outboundSchema = Payload$outboundSchema; + /** @deprecated use `Payload$Outbound` instead. */ + export type Outbound = Payload$Outbound; } -export function messageActionResultPayloadToJSON( - messageActionResultPayload: MessageActionResultPayload, -): string { - return JSON.stringify( - MessageActionResultPayload$outboundSchema.parse(messageActionResultPayload), - ); +export function payloadToJSON(payload: Payload): string { + return JSON.stringify(Payload$outboundSchema.parse(payload)); } -export function messageActionResultPayloadFromJSON( +export function payloadFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => MessageActionResultPayload$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'MessageActionResultPayload' from JSON`, + (x) => Payload$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Payload' from JSON`, ); } @@ -82,13 +75,13 @@ export const MessageActionResult$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - payload: z.lazy(() => MessageActionResultPayload$inboundSchema).optional(), + payload: z.lazy(() => Payload$inboundSchema).optional(), type: ButtonTypeEnum$inboundSchema.optional(), }); /** @internal */ export type MessageActionResult$Outbound = { - payload?: MessageActionResultPayload$Outbound | undefined; + payload?: Payload$Outbound | undefined; type?: string | undefined; }; @@ -98,7 +91,7 @@ export const MessageActionResult$outboundSchema: z.ZodType< z.ZodTypeDef, MessageActionResult > = z.object({ - payload: z.lazy(() => MessageActionResultPayload$outboundSchema).optional(), + payload: z.lazy(() => Payload$outboundSchema).optional(), type: ButtonTypeEnum$outboundSchema.optional(), }); diff --git a/src/models/components/messagecta.ts b/src/models/components/messagecta.ts index 80bccf95..84ee2994 100644 --- a/src/models/components/messagecta.ts +++ b/src/models/components/messagecta.ts @@ -32,7 +32,7 @@ export type MessageCTA = { /** * Data associated with the call to action */ - data: MessageCTAData; + data?: MessageCTAData | undefined; /** * Action associated with the call to action */ @@ -46,14 +46,14 @@ export const MessageCTA$inboundSchema: z.ZodType< unknown > = z.object({ type: ChannelCTATypeEnum$inboundSchema.optional(), - data: MessageCTAData$inboundSchema, + data: MessageCTAData$inboundSchema.optional(), action: MessageAction$inboundSchema.optional(), }); /** @internal */ export type MessageCTA$Outbound = { type?: string | undefined; - data: MessageCTAData$Outbound; + data?: MessageCTAData$Outbound | undefined; action?: MessageAction$Outbound | undefined; }; @@ -64,7 +64,7 @@ export const MessageCTA$outboundSchema: z.ZodType< MessageCTA > = z.object({ type: ChannelCTATypeEnum$outboundSchema.optional(), - data: MessageCTAData$outboundSchema, + data: MessageCTAData$outboundSchema.optional(), action: MessageAction$outboundSchema.optional(), }); diff --git a/src/models/components/messageresponsedto.ts b/src/models/components/messageresponsedto.ts index 4242a39e..906109cb 100644 --- a/src/models/components/messageresponsedto.ts +++ b/src/models/components/messageresponsedto.ts @@ -45,7 +45,7 @@ import { /** * Content of the message, can be an email block or a string */ -export type Content = EmailBlock | string; +export type Content = Array | string; /** * The payload that was used to send the notification trigger @@ -102,6 +102,10 @@ export type MessageResponseDto = { * Creation date of the message */ createdAt: string; + /** + * Array of delivery dates for the message, if the message has multiple delivery dates, for example after being snoozed + */ + deliveredAt?: Array | undefined; /** * Last seen date of the message, if available */ @@ -113,7 +117,7 @@ export type MessageResponseDto = { /** * Content of the message, can be an email block or a string */ - content: EmailBlock | string; + content: Array | string; /** * Transaction ID associated with the message */ @@ -134,6 +138,10 @@ export type MessageResponseDto = { * Indicates if the message has been seen */ seen: boolean; + /** + * Date when the message will be unsnoozed + */ + snoozedUntil?: string | undefined; /** * Email address associated with the message, if applicable */ @@ -190,17 +198,17 @@ export type MessageResponseDto = { /** @internal */ export const Content$inboundSchema: z.ZodType = - z.union([EmailBlock$inboundSchema, z.string()]); + z.union([z.array(EmailBlock$inboundSchema), z.string()]); /** @internal */ -export type Content$Outbound = EmailBlock$Outbound | string; +export type Content$Outbound = Array | string; /** @internal */ export const Content$outboundSchema: z.ZodType< Content$Outbound, z.ZodTypeDef, Content -> = z.union([EmailBlock$outboundSchema, z.string()]); +> = z.union([z.array(EmailBlock$outboundSchema), z.string()]); /** * @internal @@ -344,14 +352,16 @@ export const MessageResponseDto$inboundSchema: z.ZodType< template: WorkflowResponse$inboundSchema.optional(), templateIdentifier: z.string().optional(), createdAt: z.string(), + deliveredAt: z.array(z.string()).optional(), lastSeenDate: z.string().optional(), lastReadDate: z.string().optional(), - content: z.union([EmailBlock$inboundSchema, z.string()]), + content: z.union([z.array(EmailBlock$inboundSchema), z.string()]), transactionId: z.string(), subject: z.string().optional(), channel: ChannelTypeEnum$inboundSchema, read: z.boolean(), seen: z.boolean(), + snoozedUntil: z.string().optional(), email: z.string().optional(), phone: z.string().optional(), directWebhookUrl: z.string().optional(), @@ -391,14 +401,16 @@ export type MessageResponseDto$Outbound = { template?: WorkflowResponse$Outbound | undefined; templateIdentifier?: string | undefined; createdAt: string; + deliveredAt?: Array | undefined; lastSeenDate?: string | undefined; lastReadDate?: string | undefined; - content: EmailBlock$Outbound | string; + content: Array | string; transactionId: string; subject?: string | undefined; channel: string; read: boolean; seen: boolean; + snoozedUntil?: string | undefined; email?: string | undefined; phone?: string | undefined; directWebhookUrl?: string | undefined; @@ -431,14 +443,16 @@ export const MessageResponseDto$outboundSchema: z.ZodType< template: WorkflowResponse$outboundSchema.optional(), templateIdentifier: z.string().optional(), createdAt: z.string(), + deliveredAt: z.array(z.string()).optional(), lastSeenDate: z.string().optional(), lastReadDate: z.string().optional(), - content: z.union([EmailBlock$outboundSchema, z.string()]), + content: z.union([z.array(EmailBlock$outboundSchema), z.string()]), transactionId: z.string(), subject: z.string().optional(), channel: ChannelTypeEnum$outboundSchema, read: z.boolean(), seen: z.boolean(), + snoozedUntil: z.string().optional(), email: z.string().optional(), phone: z.string().optional(), directWebhookUrl: z.string().optional(), diff --git a/src/models/components/messagesresponsedto.ts b/src/models/components/messagesresponsedto.ts new file mode 100644 index 00000000..68b6c5f7 --- /dev/null +++ b/src/models/components/messagesresponsedto.ts @@ -0,0 +1,103 @@ +/* + * 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"; +import { + MessageResponseDto, + MessageResponseDto$inboundSchema, + MessageResponseDto$Outbound, + MessageResponseDto$outboundSchema, +} from "./messageresponsedto.js"; + +export type MessagesResponseDto = { + /** + * Total number of messages available + */ + totalCount?: number | undefined; + /** + * Indicates if there are more messages available + */ + hasMore: boolean; + /** + * List of messages + */ + data: Array; + /** + * Number of messages per page + */ + pageSize: number; + /** + * Current page number + */ + page: number; +}; + +/** @internal */ +export const MessagesResponseDto$inboundSchema: z.ZodType< + MessagesResponseDto, + z.ZodTypeDef, + unknown +> = z.object({ + totalCount: z.number().optional(), + hasMore: z.boolean(), + data: z.array(MessageResponseDto$inboundSchema), + pageSize: z.number(), + page: z.number(), +}); + +/** @internal */ +export type MessagesResponseDto$Outbound = { + totalCount?: number | undefined; + hasMore: boolean; + data: Array; + pageSize: number; + page: number; +}; + +/** @internal */ +export const MessagesResponseDto$outboundSchema: z.ZodType< + MessagesResponseDto$Outbound, + z.ZodTypeDef, + MessagesResponseDto +> = z.object({ + totalCount: z.number().optional(), + hasMore: z.boolean(), + data: z.array(MessageResponseDto$outboundSchema), + pageSize: z.number(), + page: z.number(), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace MessagesResponseDto$ { + /** @deprecated use `MessagesResponseDto$inboundSchema` instead. */ + export const inboundSchema = MessagesResponseDto$inboundSchema; + /** @deprecated use `MessagesResponseDto$outboundSchema` instead. */ + export const outboundSchema = MessagesResponseDto$outboundSchema; + /** @deprecated use `MessagesResponseDto$Outbound` instead. */ + export type Outbound = MessagesResponseDto$Outbound; +} + +export function messagesResponseDtoToJSON( + messagesResponseDto: MessagesResponseDto, +): string { + return JSON.stringify( + MessagesResponseDto$outboundSchema.parse(messagesResponseDto), + ); +} + +export function messagesResponseDtoFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => MessagesResponseDto$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'MessagesResponseDto' from JSON`, + ); +} diff --git a/src/models/components/notificationfeeditemdto.ts b/src/models/components/notificationfeeditemdto.ts index e3d48173..1be50274 100644 --- a/src/models/components/notificationfeeditemdto.ts +++ b/src/models/components/notificationfeeditemdto.ts @@ -132,10 +132,6 @@ export type NotificationFeedItemDto = { * Indicates whether the notification has been seen by the subscriber. */ seen: boolean; - /** - * Indicates whether the notification has been deleted. - */ - deleted: boolean; /** * Device tokens for push notifications, if applicable. */ @@ -210,7 +206,6 @@ export const NotificationFeedItemDto$inboundSchema: z.ZodType< channel: ChannelTypeEnum$inboundSchema, read: z.boolean(), seen: z.boolean(), - deleted: z.boolean(), deviceTokens: z.nullable(z.array(z.string())).optional(), cta: MessageCTA$inboundSchema, status: NotificationFeedItemDtoStatus$inboundSchema, @@ -253,7 +248,6 @@ export type NotificationFeedItemDto$Outbound = { channel: string; read: boolean; seen: boolean; - deleted: boolean; deviceTokens?: Array | null | undefined; cta: MessageCTA$Outbound; status: string; @@ -288,7 +282,6 @@ export const NotificationFeedItemDto$outboundSchema: z.ZodType< channel: ChannelTypeEnum$outboundSchema, read: z.boolean(), seen: z.boolean(), - deleted: z.boolean(), deviceTokens: z.nullable(z.array(z.string())).optional(), cta: MessageCTA$outboundSchema, status: NotificationFeedItemDtoStatus$outboundSchema, diff --git a/src/models/components/notificationstepdto.ts b/src/models/components/notificationstepdto.ts index 8bfa52eb..273f1fd2 100644 --- a/src/models/components/notificationstepdto.ts +++ b/src/models/components/notificationstepdto.ts @@ -59,7 +59,7 @@ import { /** * Metadata associated with the workflow step. Can vary based on the type of step. */ -export type NotificationStepDtoMetadata = +export type Metadata = | DelayScheduledMetadata | DelayRegularMetadata | DigestTimedMetadata @@ -119,8 +119,8 @@ export type NotificationStepDto = { }; /** @internal */ -export const NotificationStepDtoMetadata$inboundSchema: z.ZodType< - NotificationStepDtoMetadata, +export const Metadata$inboundSchema: z.ZodType< + Metadata, z.ZodTypeDef, unknown > = z.union([ @@ -131,17 +131,17 @@ export const NotificationStepDtoMetadata$inboundSchema: z.ZodType< ]); /** @internal */ -export type NotificationStepDtoMetadata$Outbound = +export type Metadata$Outbound = | DelayScheduledMetadata$Outbound | DelayRegularMetadata$Outbound | DigestTimedMetadata$Outbound | DigestRegularMetadata$Outbound; /** @internal */ -export const NotificationStepDtoMetadata$outboundSchema: z.ZodType< - NotificationStepDtoMetadata$Outbound, +export const Metadata$outboundSchema: z.ZodType< + Metadata$Outbound, z.ZodTypeDef, - NotificationStepDtoMetadata + Metadata > = z.union([ DelayScheduledMetadata$outboundSchema, DelayRegularMetadata$outboundSchema, @@ -153,32 +153,26 @@ export const NotificationStepDtoMetadata$outboundSchema: z.ZodType< * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace NotificationStepDtoMetadata$ { - /** @deprecated use `NotificationStepDtoMetadata$inboundSchema` instead. */ - export const inboundSchema = NotificationStepDtoMetadata$inboundSchema; - /** @deprecated use `NotificationStepDtoMetadata$outboundSchema` instead. */ - export const outboundSchema = NotificationStepDtoMetadata$outboundSchema; - /** @deprecated use `NotificationStepDtoMetadata$Outbound` instead. */ - export type Outbound = NotificationStepDtoMetadata$Outbound; +export namespace Metadata$ { + /** @deprecated use `Metadata$inboundSchema` instead. */ + export const inboundSchema = Metadata$inboundSchema; + /** @deprecated use `Metadata$outboundSchema` instead. */ + export const outboundSchema = Metadata$outboundSchema; + /** @deprecated use `Metadata$Outbound` instead. */ + export type Outbound = Metadata$Outbound; } -export function notificationStepDtoMetadataToJSON( - notificationStepDtoMetadata: NotificationStepDtoMetadata, -): string { - return JSON.stringify( - NotificationStepDtoMetadata$outboundSchema.parse( - notificationStepDtoMetadata, - ), - ); +export function metadataToJSON(metadata: Metadata): string { + return JSON.stringify(Metadata$outboundSchema.parse(metadata)); } -export function notificationStepDtoMetadataFromJSON( +export function metadataFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => NotificationStepDtoMetadata$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'NotificationStepDtoMetadata' from JSON`, + (x) => Metadata$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Metadata' from JSON`, ); } diff --git a/src/models/components/notificationtriggerdto.ts b/src/models/components/notificationtriggerdto.ts index eb21f9e2..4d7a68e4 100644 --- a/src/models/components/notificationtriggerdto.ts +++ b/src/models/components/notificationtriggerdto.ts @@ -17,19 +17,21 @@ import { /** * Type of the trigger */ -export const Type = { +export const NotificationTriggerDtoType = { Event: "event", } as const; /** * Type of the trigger */ -export type Type = ClosedEnum; +export type NotificationTriggerDtoType = ClosedEnum< + typeof NotificationTriggerDtoType +>; export type NotificationTriggerDto = { /** * Type of the trigger */ - type: Type; + type: NotificationTriggerDtoType; /** * Identifier of the trigger */ @@ -45,23 +47,24 @@ export type NotificationTriggerDto = { }; /** @internal */ -export const Type$inboundSchema: z.ZodNativeEnum = z.nativeEnum( - Type, -); +export const NotificationTriggerDtoType$inboundSchema: z.ZodNativeEnum< + typeof NotificationTriggerDtoType +> = z.nativeEnum(NotificationTriggerDtoType); /** @internal */ -export const Type$outboundSchema: z.ZodNativeEnum = - Type$inboundSchema; +export const NotificationTriggerDtoType$outboundSchema: z.ZodNativeEnum< + typeof NotificationTriggerDtoType +> = NotificationTriggerDtoType$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Type$ { - /** @deprecated use `Type$inboundSchema` instead. */ - export const inboundSchema = Type$inboundSchema; - /** @deprecated use `Type$outboundSchema` instead. */ - export const outboundSchema = Type$outboundSchema; +export namespace NotificationTriggerDtoType$ { + /** @deprecated use `NotificationTriggerDtoType$inboundSchema` instead. */ + export const inboundSchema = NotificationTriggerDtoType$inboundSchema; + /** @deprecated use `NotificationTriggerDtoType$outboundSchema` instead. */ + export const outboundSchema = NotificationTriggerDtoType$outboundSchema; } /** @internal */ @@ -70,7 +73,7 @@ export const NotificationTriggerDto$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - type: Type$inboundSchema, + type: NotificationTriggerDtoType$inboundSchema, identifier: z.string(), variables: z.array(NotificationTriggerVariable$inboundSchema), subscriberVariables: z.array(NotificationTriggerVariable$inboundSchema) @@ -91,7 +94,7 @@ export const NotificationTriggerDto$outboundSchema: z.ZodType< z.ZodTypeDef, NotificationTriggerDto > = z.object({ - type: Type$outboundSchema, + type: NotificationTriggerDtoType$outboundSchema, identifier: z.string(), variables: z.array(NotificationTriggerVariable$outboundSchema), subscriberVariables: z.array(NotificationTriggerVariable$outboundSchema) diff --git a/src/models/components/overrides.ts b/src/models/components/overrides.ts deleted file mode 100644 index feab360b..00000000 --- a/src/models/components/overrides.ts +++ /dev/null @@ -1,139 +0,0 @@ -/* - * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - */ - -import * as z from "zod"; -import { safeParse } from "../../lib/schemas.js"; -import { ClosedEnum } from "../../types/enums.js"; -import { Result as SafeParseResult } from "../../types/fp.js"; -import { SDKValidationError } from "../errors/sdkvalidationerror.js"; - -/** - * The channel type which is overridden - */ -export const Channel = { - InApp: "in_app", - Email: "email", - Sms: "sms", - Chat: "chat", - Push: "push", -} as const; -/** - * The channel type which is overridden - */ -export type Channel = ClosedEnum; - -/** - * The source of overrides - */ -export const Source = { - Subscriber: "subscriber", - Template: "template", - WorkflowOverride: "workflowOverride", -} as const; -/** - * The source of overrides - */ -export type Source = ClosedEnum; - -export type Overrides = { - /** - * The channel type which is overridden - */ - channel: Channel; - /** - * The source of overrides - */ - source: Source; -}; - -/** @internal */ -export const Channel$inboundSchema: z.ZodNativeEnum = z - .nativeEnum(Channel); - -/** @internal */ -export const Channel$outboundSchema: z.ZodNativeEnum = - Channel$inboundSchema; - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace Channel$ { - /** @deprecated use `Channel$inboundSchema` instead. */ - export const inboundSchema = Channel$inboundSchema; - /** @deprecated use `Channel$outboundSchema` instead. */ - export const outboundSchema = Channel$outboundSchema; -} - -/** @internal */ -export const Source$inboundSchema: z.ZodNativeEnum = z - .nativeEnum(Source); - -/** @internal */ -export const Source$outboundSchema: z.ZodNativeEnum = - Source$inboundSchema; - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace Source$ { - /** @deprecated use `Source$inboundSchema` instead. */ - export const inboundSchema = Source$inboundSchema; - /** @deprecated use `Source$outboundSchema` instead. */ - export const outboundSchema = Source$outboundSchema; -} - -/** @internal */ -export const Overrides$inboundSchema: z.ZodType< - Overrides, - z.ZodTypeDef, - unknown -> = z.object({ - channel: Channel$inboundSchema, - source: Source$inboundSchema, -}); - -/** @internal */ -export type Overrides$Outbound = { - channel: string; - source: string; -}; - -/** @internal */ -export const Overrides$outboundSchema: z.ZodType< - Overrides$Outbound, - z.ZodTypeDef, - Overrides -> = z.object({ - channel: Channel$outboundSchema, - source: Source$outboundSchema, -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace Overrides$ { - /** @deprecated use `Overrides$inboundSchema` instead. */ - export const inboundSchema = Overrides$inboundSchema; - /** @deprecated use `Overrides$outboundSchema` instead. */ - export const outboundSchema = Overrides$outboundSchema; - /** @deprecated use `Overrides$Outbound` instead. */ - export type Outbound = Overrides$Outbound; -} - -export function overridesToJSON(overrides: Overrides): string { - return JSON.stringify(Overrides$outboundSchema.parse(overrides)); -} - -export function overridesFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => Overrides$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'Overrides' from JSON`, - ); -} diff --git a/src/models/components/patchsubscriberpreferencesdto.ts b/src/models/components/patchsubscriberpreferencesdto.ts index 16c4d4c2..afec04be 100644 --- a/src/models/components/patchsubscriberpreferencesdto.ts +++ b/src/models/components/patchsubscriberpreferencesdto.ts @@ -19,7 +19,7 @@ export type PatchSubscriberPreferencesDto = { */ channels: PatchPreferenceChannelsDto; /** - * If provided, update workflow specific preferences, otherwise update global preferences + * Workflow internal _id, identifier or slug. If provided, update workflow specific preferences, otherwise update global preferences */ workflowId?: string | undefined; }; diff --git a/src/models/components/preferencechannels.ts b/src/models/components/preferencechannels.ts deleted file mode 100644 index b4022c33..00000000 --- a/src/models/components/preferencechannels.ts +++ /dev/null @@ -1,91 +0,0 @@ -/* - * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - */ - -import * as z from "zod"; -import { remap as remap$ } from "../../lib/primitives.js"; -import { safeParse } from "../../lib/schemas.js"; -import { Result as SafeParseResult } from "../../types/fp.js"; -import { SDKValidationError } from "../errors/sdkvalidationerror.js"; - -export type PreferenceChannels = { - email?: boolean | undefined; - sms?: boolean | undefined; - inApp?: boolean | undefined; - chat?: boolean | undefined; - push?: boolean | undefined; -}; - -/** @internal */ -export const PreferenceChannels$inboundSchema: z.ZodType< - PreferenceChannels, - z.ZodTypeDef, - unknown -> = z.object({ - email: z.boolean().optional(), - sms: z.boolean().optional(), - in_app: z.boolean().optional(), - chat: z.boolean().optional(), - push: z.boolean().optional(), -}).transform((v) => { - return remap$(v, { - "in_app": "inApp", - }); -}); - -/** @internal */ -export type PreferenceChannels$Outbound = { - email?: boolean | undefined; - sms?: boolean | undefined; - in_app?: boolean | undefined; - chat?: boolean | undefined; - push?: boolean | undefined; -}; - -/** @internal */ -export const PreferenceChannels$outboundSchema: z.ZodType< - PreferenceChannels$Outbound, - z.ZodTypeDef, - PreferenceChannels -> = z.object({ - email: z.boolean().optional(), - sms: z.boolean().optional(), - inApp: z.boolean().optional(), - chat: z.boolean().optional(), - push: z.boolean().optional(), -}).transform((v) => { - return remap$(v, { - inApp: "in_app", - }); -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace PreferenceChannels$ { - /** @deprecated use `PreferenceChannels$inboundSchema` instead. */ - export const inboundSchema = PreferenceChannels$inboundSchema; - /** @deprecated use `PreferenceChannels$outboundSchema` instead. */ - export const outboundSchema = PreferenceChannels$outboundSchema; - /** @deprecated use `PreferenceChannels$Outbound` instead. */ - export type Outbound = PreferenceChannels$Outbound; -} - -export function preferenceChannelsToJSON( - preferenceChannels: PreferenceChannels, -): string { - return JSON.stringify( - PreferenceChannels$outboundSchema.parse(preferenceChannels), - ); -} - -export function preferenceChannelsFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => PreferenceChannels$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'PreferenceChannels' from JSON`, - ); -} diff --git a/src/models/components/preferenceoverridesourceenum.ts b/src/models/components/preferenceoverridesourceenum.ts new file mode 100644 index 00000000..930a3af9 --- /dev/null +++ b/src/models/components/preferenceoverridesourceenum.ts @@ -0,0 +1,42 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { ClosedEnum } from "../../types/enums.js"; + +/** + * The source of overrides + */ +export const PreferenceOverrideSourceEnum = { + Subscriber: "subscriber", + Template: "template", + WorkflowOverride: "workflowOverride", +} as const; +/** + * The source of overrides + */ +export type PreferenceOverrideSourceEnum = ClosedEnum< + typeof PreferenceOverrideSourceEnum +>; + +/** @internal */ +export const PreferenceOverrideSourceEnum$inboundSchema: z.ZodNativeEnum< + typeof PreferenceOverrideSourceEnum +> = z.nativeEnum(PreferenceOverrideSourceEnum); + +/** @internal */ +export const PreferenceOverrideSourceEnum$outboundSchema: z.ZodNativeEnum< + typeof PreferenceOverrideSourceEnum +> = PreferenceOverrideSourceEnum$inboundSchema; + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace PreferenceOverrideSourceEnum$ { + /** @deprecated use `PreferenceOverrideSourceEnum$inboundSchema` instead. */ + export const inboundSchema = PreferenceOverrideSourceEnum$inboundSchema; + /** @deprecated use `PreferenceOverrideSourceEnum$outboundSchema` instead. */ + export const outboundSchema = PreferenceOverrideSourceEnum$outboundSchema; +} diff --git a/src/models/components/providersidenum.ts b/src/models/components/providersidenum.ts index 8ab6999e..a637d493 100644 --- a/src/models/components/providersidenum.ts +++ b/src/models/components/providersidenum.ts @@ -60,6 +60,7 @@ export const ProvidersIdEnum = { BrevoSms: "brevo-sms", EazySms: "eazy-sms", Mobishastra: "mobishastra", + AfroMessage: "afro-message", Fcm: "fcm", Apns: "apns", Expo: "expo", diff --git a/src/models/components/stepfilterdto.ts b/src/models/components/stepfilterdto.ts index 8745cea3..008f0fd3 100644 --- a/src/models/components/stepfilterdto.ts +++ b/src/models/components/stepfilterdto.ts @@ -19,37 +19,38 @@ import { FieldFilterPartDto$outboundSchema, } from "./fieldfilterpartdto.js"; -export const Value = { +export const StepFilterDtoValue = { And: "AND", Or: "OR", } as const; -export type Value = ClosedEnum; +export type StepFilterDtoValue = ClosedEnum; export type StepFilterDto = { isNegated: boolean; type: BuilderFieldTypeEnum; - value: Value; + value: StepFilterDtoValue; children: Array; }; /** @internal */ -export const Value$inboundSchema: z.ZodNativeEnum = z.nativeEnum( - Value, -); +export const StepFilterDtoValue$inboundSchema: z.ZodNativeEnum< + typeof StepFilterDtoValue +> = z.nativeEnum(StepFilterDtoValue); /** @internal */ -export const Value$outboundSchema: z.ZodNativeEnum = - Value$inboundSchema; +export const StepFilterDtoValue$outboundSchema: z.ZodNativeEnum< + typeof StepFilterDtoValue +> = StepFilterDtoValue$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Value$ { - /** @deprecated use `Value$inboundSchema` instead. */ - export const inboundSchema = Value$inboundSchema; - /** @deprecated use `Value$outboundSchema` instead. */ - export const outboundSchema = Value$outboundSchema; +export namespace StepFilterDtoValue$ { + /** @deprecated use `StepFilterDtoValue$inboundSchema` instead. */ + export const inboundSchema = StepFilterDtoValue$inboundSchema; + /** @deprecated use `StepFilterDtoValue$outboundSchema` instead. */ + export const outboundSchema = StepFilterDtoValue$outboundSchema; } /** @internal */ @@ -60,7 +61,7 @@ export const StepFilterDto$inboundSchema: z.ZodType< > = z.object({ isNegated: z.boolean(), type: BuilderFieldTypeEnum$inboundSchema, - value: Value$inboundSchema, + value: StepFilterDtoValue$inboundSchema, children: z.array(FieldFilterPartDto$inboundSchema), }); @@ -80,7 +81,7 @@ export const StepFilterDto$outboundSchema: z.ZodType< > = z.object({ isNegated: z.boolean(), type: BuilderFieldTypeEnum$outboundSchema, - value: Value$outboundSchema, + value: StepFilterDtoValue$outboundSchema, children: z.array(FieldFilterPartDto$outboundSchema), }); diff --git a/src/models/components/stepsoverrides.ts b/src/models/components/stepsoverrides.ts new file mode 100644 index 00000000..199019a3 --- /dev/null +++ b/src/models/components/stepsoverrides.ts @@ -0,0 +1,65 @@ +/* + * 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 StepsOverrides = { + /** + * Passing the provider id and the provider specific configurations + */ + providers: { [k: string]: { [k: string]: any } }; +}; + +/** @internal */ +export const StepsOverrides$inboundSchema: z.ZodType< + StepsOverrides, + z.ZodTypeDef, + unknown +> = z.object({ + providers: z.record(z.record(z.any())), +}); + +/** @internal */ +export type StepsOverrides$Outbound = { + providers: { [k: string]: { [k: string]: any } }; +}; + +/** @internal */ +export const StepsOverrides$outboundSchema: z.ZodType< + StepsOverrides$Outbound, + z.ZodTypeDef, + StepsOverrides +> = z.object({ + providers: z.record(z.record(z.any())), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace StepsOverrides$ { + /** @deprecated use `StepsOverrides$inboundSchema` instead. */ + export const inboundSchema = StepsOverrides$inboundSchema; + /** @deprecated use `StepsOverrides$outboundSchema` instead. */ + export const outboundSchema = StepsOverrides$outboundSchema; + /** @deprecated use `StepsOverrides$Outbound` instead. */ + export type Outbound = StepsOverrides$Outbound; +} + +export function stepsOverridesToJSON(stepsOverrides: StepsOverrides): string { + return JSON.stringify(StepsOverrides$outboundSchema.parse(stepsOverrides)); +} + +export function stepsOverridesFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => StepsOverrides$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'StepsOverrides' from JSON`, + ); +} diff --git a/src/models/components/steptypeenum.ts b/src/models/components/steptypeenum.ts index 385de6b2..6fad5c07 100644 --- a/src/models/components/steptypeenum.ts +++ b/src/models/components/steptypeenum.ts @@ -6,7 +6,7 @@ import * as z from "zod"; import { ClosedEnum } from "../../types/enums.js"; /** - * Channels of the notification + * Type of the step */ export const StepTypeEnum = { InApp: "in_app", @@ -20,7 +20,7 @@ export const StepTypeEnum = { Custom: "custom", } as const; /** - * Channels of the notification + * Type of the step */ export type StepTypeEnum = ClosedEnum; diff --git a/src/models/components/subscriberchanneldto.ts b/src/models/components/subscriberchanneldto.ts index 98e5316f..1746ca6f 100644 --- a/src/models/components/subscriberchanneldto.ts +++ b/src/models/components/subscriberchanneldto.ts @@ -17,7 +17,7 @@ import { /** * The ID of the chat or push provider. */ -export const SubscriberChannelDtoProviderId = { +export const ProviderId = { Slack: "slack", Discord: "discord", Msteams: "msteams", @@ -39,15 +39,13 @@ export const SubscriberChannelDtoProviderId = { /** * The ID of the chat or push provider. */ -export type SubscriberChannelDtoProviderId = ClosedEnum< - typeof SubscriberChannelDtoProviderId ->; +export type ProviderId = ClosedEnum; export type SubscriberChannelDto = { /** * The ID of the chat or push provider. */ - providerId: SubscriberChannelDtoProviderId; + providerId: ProviderId; /** * An optional identifier for the integration. */ @@ -59,24 +57,22 @@ export type SubscriberChannelDto = { }; /** @internal */ -export const SubscriberChannelDtoProviderId$inboundSchema: z.ZodNativeEnum< - typeof SubscriberChannelDtoProviderId -> = z.nativeEnum(SubscriberChannelDtoProviderId); +export const ProviderId$inboundSchema: z.ZodNativeEnum = z + .nativeEnum(ProviderId); /** @internal */ -export const SubscriberChannelDtoProviderId$outboundSchema: z.ZodNativeEnum< - typeof SubscriberChannelDtoProviderId -> = SubscriberChannelDtoProviderId$inboundSchema; +export const ProviderId$outboundSchema: z.ZodNativeEnum = + ProviderId$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace SubscriberChannelDtoProviderId$ { - /** @deprecated use `SubscriberChannelDtoProviderId$inboundSchema` instead. */ - export const inboundSchema = SubscriberChannelDtoProviderId$inboundSchema; - /** @deprecated use `SubscriberChannelDtoProviderId$outboundSchema` instead. */ - export const outboundSchema = SubscriberChannelDtoProviderId$outboundSchema; +export namespace ProviderId$ { + /** @deprecated use `ProviderId$inboundSchema` instead. */ + export const inboundSchema = ProviderId$inboundSchema; + /** @deprecated use `ProviderId$outboundSchema` instead. */ + export const outboundSchema = ProviderId$outboundSchema; } /** @internal */ @@ -85,7 +81,7 @@ export const SubscriberChannelDto$inboundSchema: z.ZodType< z.ZodTypeDef, unknown > = z.object({ - providerId: SubscriberChannelDtoProviderId$inboundSchema, + providerId: ProviderId$inboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentialsDto$inboundSchema, }); @@ -103,7 +99,7 @@ export const SubscriberChannelDto$outboundSchema: z.ZodType< z.ZodTypeDef, SubscriberChannelDto > = z.object({ - providerId: SubscriberChannelDtoProviderId$outboundSchema, + providerId: ProviderId$outboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentialsDto$outboundSchema, }); diff --git a/src/models/components/subscriberglobalpreferencedto.ts b/src/models/components/subscriberglobalpreferencedto.ts new file mode 100644 index 00000000..b2fdbbe7 --- /dev/null +++ b/src/models/components/subscriberglobalpreferencedto.ts @@ -0,0 +1,84 @@ +/* + * 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"; +import { + SubscriberPreferenceChannels, + SubscriberPreferenceChannels$inboundSchema, + SubscriberPreferenceChannels$Outbound, + SubscriberPreferenceChannels$outboundSchema, +} from "./subscriberpreferencechannels.js"; + +export type SubscriberGlobalPreferenceDto = { + /** + * Whether notifications are enabled globally + */ + enabled: boolean; + /** + * Channel-specific preference settings + */ + channels: SubscriberPreferenceChannels; +}; + +/** @internal */ +export const SubscriberGlobalPreferenceDto$inboundSchema: z.ZodType< + SubscriberGlobalPreferenceDto, + z.ZodTypeDef, + unknown +> = z.object({ + enabled: z.boolean(), + channels: SubscriberPreferenceChannels$inboundSchema, +}); + +/** @internal */ +export type SubscriberGlobalPreferenceDto$Outbound = { + enabled: boolean; + channels: SubscriberPreferenceChannels$Outbound; +}; + +/** @internal */ +export const SubscriberGlobalPreferenceDto$outboundSchema: z.ZodType< + SubscriberGlobalPreferenceDto$Outbound, + z.ZodTypeDef, + SubscriberGlobalPreferenceDto +> = z.object({ + enabled: z.boolean(), + channels: SubscriberPreferenceChannels$outboundSchema, +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SubscriberGlobalPreferenceDto$ { + /** @deprecated use `SubscriberGlobalPreferenceDto$inboundSchema` instead. */ + export const inboundSchema = SubscriberGlobalPreferenceDto$inboundSchema; + /** @deprecated use `SubscriberGlobalPreferenceDto$outboundSchema` instead. */ + export const outboundSchema = SubscriberGlobalPreferenceDto$outboundSchema; + /** @deprecated use `SubscriberGlobalPreferenceDto$Outbound` instead. */ + export type Outbound = SubscriberGlobalPreferenceDto$Outbound; +} + +export function subscriberGlobalPreferenceDtoToJSON( + subscriberGlobalPreferenceDto: SubscriberGlobalPreferenceDto, +): string { + return JSON.stringify( + SubscriberGlobalPreferenceDto$outboundSchema.parse( + subscriberGlobalPreferenceDto, + ), + ); +} + +export function subscriberGlobalPreferenceDtoFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SubscriberGlobalPreferenceDto$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SubscriberGlobalPreferenceDto' from JSON`, + ); +} diff --git a/src/models/components/subscriberpreferencechannels.ts b/src/models/components/subscriberpreferencechannels.ts new file mode 100644 index 00000000..02831b46 --- /dev/null +++ b/src/models/components/subscriberpreferencechannels.ts @@ -0,0 +1,108 @@ +/* + * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. + */ + +import * as z from "zod"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { safeParse } from "../../lib/schemas.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "../errors/sdkvalidationerror.js"; + +export type SubscriberPreferenceChannels = { + /** + * Email channel preference + */ + email?: boolean | undefined; + /** + * SMS channel preference + */ + sms?: boolean | undefined; + /** + * In-app channel preference + */ + inApp?: boolean | undefined; + /** + * Chat channel preference + */ + chat?: boolean | undefined; + /** + * Push notification channel preference + */ + push?: boolean | undefined; +}; + +/** @internal */ +export const SubscriberPreferenceChannels$inboundSchema: z.ZodType< + SubscriberPreferenceChannels, + z.ZodTypeDef, + unknown +> = z.object({ + email: z.boolean().optional(), + sms: z.boolean().optional(), + in_app: z.boolean().optional(), + chat: z.boolean().optional(), + push: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + "in_app": "inApp", + }); +}); + +/** @internal */ +export type SubscriberPreferenceChannels$Outbound = { + email?: boolean | undefined; + sms?: boolean | undefined; + in_app?: boolean | undefined; + chat?: boolean | undefined; + push?: boolean | undefined; +}; + +/** @internal */ +export const SubscriberPreferenceChannels$outboundSchema: z.ZodType< + SubscriberPreferenceChannels$Outbound, + z.ZodTypeDef, + SubscriberPreferenceChannels +> = z.object({ + email: z.boolean().optional(), + sms: z.boolean().optional(), + inApp: z.boolean().optional(), + chat: z.boolean().optional(), + push: z.boolean().optional(), +}).transform((v) => { + return remap$(v, { + inApp: "in_app", + }); +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SubscriberPreferenceChannels$ { + /** @deprecated use `SubscriberPreferenceChannels$inboundSchema` instead. */ + export const inboundSchema = SubscriberPreferenceChannels$inboundSchema; + /** @deprecated use `SubscriberPreferenceChannels$outboundSchema` instead. */ + export const outboundSchema = SubscriberPreferenceChannels$outboundSchema; + /** @deprecated use `SubscriberPreferenceChannels$Outbound` instead. */ + export type Outbound = SubscriberPreferenceChannels$Outbound; +} + +export function subscriberPreferenceChannelsToJSON( + subscriberPreferenceChannels: SubscriberPreferenceChannels, +): string { + return JSON.stringify( + SubscriberPreferenceChannels$outboundSchema.parse( + subscriberPreferenceChannels, + ), + ); +} + +export function subscriberPreferenceChannelsFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SubscriberPreferenceChannels$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SubscriberPreferenceChannels' from JSON`, + ); +} diff --git a/src/models/components/subscriberpreferenceoverridedto.ts b/src/models/components/subscriberpreferenceoverridedto.ts new file mode 100644 index 00000000..83319fe0 --- /dev/null +++ b/src/models/components/subscriberpreferenceoverridedto.ts @@ -0,0 +1,88 @@ +/* + * 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"; +import { + ChannelTypeEnum, + ChannelTypeEnum$inboundSchema, + ChannelTypeEnum$outboundSchema, +} from "./channeltypeenum.js"; +import { + PreferenceOverrideSourceEnum, + PreferenceOverrideSourceEnum$inboundSchema, + PreferenceOverrideSourceEnum$outboundSchema, +} from "./preferenceoverridesourceenum.js"; + +export type SubscriberPreferenceOverrideDto = { + /** + * Channel type through which the message is sent + */ + channel: ChannelTypeEnum; + /** + * The source of overrides + */ + source: PreferenceOverrideSourceEnum; +}; + +/** @internal */ +export const SubscriberPreferenceOverrideDto$inboundSchema: z.ZodType< + SubscriberPreferenceOverrideDto, + z.ZodTypeDef, + unknown +> = z.object({ + channel: ChannelTypeEnum$inboundSchema, + source: PreferenceOverrideSourceEnum$inboundSchema, +}); + +/** @internal */ +export type SubscriberPreferenceOverrideDto$Outbound = { + channel: string; + source: string; +}; + +/** @internal */ +export const SubscriberPreferenceOverrideDto$outboundSchema: z.ZodType< + SubscriberPreferenceOverrideDto$Outbound, + z.ZodTypeDef, + SubscriberPreferenceOverrideDto +> = z.object({ + channel: ChannelTypeEnum$outboundSchema, + source: PreferenceOverrideSourceEnum$outboundSchema, +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SubscriberPreferenceOverrideDto$ { + /** @deprecated use `SubscriberPreferenceOverrideDto$inboundSchema` instead. */ + export const inboundSchema = SubscriberPreferenceOverrideDto$inboundSchema; + /** @deprecated use `SubscriberPreferenceOverrideDto$outboundSchema` instead. */ + export const outboundSchema = SubscriberPreferenceOverrideDto$outboundSchema; + /** @deprecated use `SubscriberPreferenceOverrideDto$Outbound` instead. */ + export type Outbound = SubscriberPreferenceOverrideDto$Outbound; +} + +export function subscriberPreferenceOverrideDtoToJSON( + subscriberPreferenceOverrideDto: SubscriberPreferenceOverrideDto, +): string { + return JSON.stringify( + SubscriberPreferenceOverrideDto$outboundSchema.parse( + subscriberPreferenceOverrideDto, + ), + ); +} + +export function subscriberPreferenceOverrideDtoFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SubscriberPreferenceOverrideDto$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SubscriberPreferenceOverrideDto' from JSON`, + ); +} diff --git a/src/models/components/subscriberpreferencesworkflowinfodto.ts b/src/models/components/subscriberpreferencesworkflowinfodto.ts new file mode 100644 index 00000000..6b72b1b8 --- /dev/null +++ b/src/models/components/subscriberpreferencesworkflowinfodto.ts @@ -0,0 +1,95 @@ +/* + * 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 SubscriberPreferencesWorkflowInfoDto = { + /** + * Workflow slug + */ + slug: string; + /** + * Unique identifier of the workflow + */ + identifier: string; + /** + * Display name of the workflow + */ + name: string; + /** + * last updated date + */ + updatedAt?: string | undefined; +}; + +/** @internal */ +export const SubscriberPreferencesWorkflowInfoDto$inboundSchema: z.ZodType< + SubscriberPreferencesWorkflowInfoDto, + z.ZodTypeDef, + unknown +> = z.object({ + slug: z.string(), + identifier: z.string(), + name: z.string(), + updatedAt: z.string().optional(), +}); + +/** @internal */ +export type SubscriberPreferencesWorkflowInfoDto$Outbound = { + slug: string; + identifier: string; + name: string; + updatedAt?: string | undefined; +}; + +/** @internal */ +export const SubscriberPreferencesWorkflowInfoDto$outboundSchema: z.ZodType< + SubscriberPreferencesWorkflowInfoDto$Outbound, + z.ZodTypeDef, + SubscriberPreferencesWorkflowInfoDto +> = z.object({ + slug: z.string(), + identifier: z.string(), + name: z.string(), + updatedAt: 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 SubscriberPreferencesWorkflowInfoDto$ { + /** @deprecated use `SubscriberPreferencesWorkflowInfoDto$inboundSchema` instead. */ + export const inboundSchema = + SubscriberPreferencesWorkflowInfoDto$inboundSchema; + /** @deprecated use `SubscriberPreferencesWorkflowInfoDto$outboundSchema` instead. */ + export const outboundSchema = + SubscriberPreferencesWorkflowInfoDto$outboundSchema; + /** @deprecated use `SubscriberPreferencesWorkflowInfoDto$Outbound` instead. */ + export type Outbound = SubscriberPreferencesWorkflowInfoDto$Outbound; +} + +export function subscriberPreferencesWorkflowInfoDtoToJSON( + subscriberPreferencesWorkflowInfoDto: SubscriberPreferencesWorkflowInfoDto, +): string { + return JSON.stringify( + SubscriberPreferencesWorkflowInfoDto$outboundSchema.parse( + subscriberPreferencesWorkflowInfoDto, + ), + ); +} + +export function subscriberPreferencesWorkflowInfoDtoFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => + SubscriberPreferencesWorkflowInfoDto$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SubscriberPreferencesWorkflowInfoDto' from JSON`, + ); +} diff --git a/src/models/components/subscriberresponsedto.ts b/src/models/components/subscriberresponsedto.ts index a8db7f38..565026b2 100644 --- a/src/models/components/subscriberresponsedto.ts +++ b/src/models/components/subscriberresponsedto.ts @@ -30,7 +30,7 @@ export type SubscriberResponseDto = { /** * The email address of the subscriber. */ - email?: string | null | undefined; + email?: string | undefined; /** * The phone number of the subscriber. */ @@ -43,10 +43,6 @@ export type SubscriberResponseDto = { * The locale setting of the subscriber, indicating their preferred language or region. */ locale?: string | undefined; - /** - * The identifier used to create this subscriber, which typically corresponds to the user ID in your system. - */ - subscriberId: string; /** * An array of channel settings associated with the subscriber. */ @@ -65,6 +61,22 @@ export type SubscriberResponseDto = { * The timestamp indicating when the subscriber was last online, in ISO 8601 format. */ lastOnlineAt?: string | undefined; + /** + * The version of the subscriber document. + */ + v?: number | undefined; + /** + * Additional custom data for the subscriber + */ + data?: { [k: string]: any } | null | undefined; + /** + * Timezone of the subscriber + */ + timezone?: string | undefined; + /** + * The identifier used to create this subscriber, which typically corresponds to the user ID in your system. + */ + subscriberId: string; /** * The unique identifier of the organization to which the subscriber belongs. */ @@ -85,18 +97,6 @@ export type SubscriberResponseDto = { * The timestamp indicating when the subscriber was last updated, in ISO 8601 format. */ updatedAt: string; - /** - * The version of the subscriber document. - */ - v?: number | undefined; - /** - * Additional custom data for the subscriber - */ - data?: { [k: string]: any } | null | undefined; - /** - * Timezone of the subscriber - */ - timezone?: string | undefined; }; /** @internal */ @@ -108,29 +108,29 @@ export const SubscriberResponseDto$inboundSchema: z.ZodType< _id: z.string().optional(), firstName: z.string().optional(), lastName: z.string().optional(), - email: z.nullable(z.string()).optional(), + email: z.string().optional(), phone: z.string().optional(), avatar: z.string().optional(), locale: z.string().optional(), - subscriberId: z.string(), channels: z.array(ChannelSettingsDto$inboundSchema).optional(), topics: z.array(z.string()).optional(), isOnline: z.boolean().optional(), lastOnlineAt: z.string().optional(), + __v: z.number().optional(), + data: z.nullable(z.record(z.any())).optional(), + timezone: z.string().optional(), + subscriberId: z.string(), _organizationId: z.string(), _environmentId: z.string(), deleted: z.boolean(), createdAt: z.string(), updatedAt: z.string(), - __v: z.number().optional(), - data: z.nullable(z.record(z.any())).optional(), - timezone: z.string().optional(), }).transform((v) => { return remap$(v, { "_id": "id", + "__v": "v", "_organizationId": "organizationId", "_environmentId": "environmentId", - "__v": "v", }); }); @@ -139,23 +139,23 @@ export type SubscriberResponseDto$Outbound = { _id?: string | undefined; firstName?: string | undefined; lastName?: string | undefined; - email?: string | null | undefined; + email?: string | undefined; phone?: string | undefined; avatar?: string | undefined; locale?: string | undefined; - subscriberId: string; channels?: Array | undefined; topics?: Array | undefined; isOnline?: boolean | undefined; lastOnlineAt?: string | undefined; + __v?: number | undefined; + data?: { [k: string]: any } | null | undefined; + timezone?: string | undefined; + subscriberId: string; _organizationId: string; _environmentId: string; deleted: boolean; createdAt: string; updatedAt: string; - __v?: number | undefined; - data?: { [k: string]: any } | null | undefined; - timezone?: string | undefined; }; /** @internal */ @@ -167,29 +167,29 @@ export const SubscriberResponseDto$outboundSchema: z.ZodType< id: z.string().optional(), firstName: z.string().optional(), lastName: z.string().optional(), - email: z.nullable(z.string()).optional(), + email: z.string().optional(), phone: z.string().optional(), avatar: z.string().optional(), locale: z.string().optional(), - subscriberId: z.string(), channels: z.array(ChannelSettingsDto$outboundSchema).optional(), topics: z.array(z.string()).optional(), isOnline: z.boolean().optional(), lastOnlineAt: z.string().optional(), + v: z.number().optional(), + data: z.nullable(z.record(z.any())).optional(), + timezone: z.string().optional(), + subscriberId: z.string(), organizationId: z.string(), environmentId: z.string(), deleted: z.boolean(), createdAt: z.string(), updatedAt: z.string(), - v: z.number().optional(), - data: z.nullable(z.record(z.any())).optional(), - timezone: z.string().optional(), }).transform((v) => { return remap$(v, { id: "_id", + v: "__v", organizationId: "_organizationId", environmentId: "_environmentId", - v: "__v", }); }); diff --git a/src/models/components/subscriberworkflowpreferencedto.ts b/src/models/components/subscriberworkflowpreferencedto.ts new file mode 100644 index 00000000..b7068f75 --- /dev/null +++ b/src/models/components/subscriberworkflowpreferencedto.ts @@ -0,0 +1,110 @@ +/* + * 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"; +import { + SubscriberPreferenceChannels, + SubscriberPreferenceChannels$inboundSchema, + SubscriberPreferenceChannels$Outbound, + SubscriberPreferenceChannels$outboundSchema, +} from "./subscriberpreferencechannels.js"; +import { + SubscriberPreferenceOverrideDto, + SubscriberPreferenceOverrideDto$inboundSchema, + SubscriberPreferenceOverrideDto$Outbound, + SubscriberPreferenceOverrideDto$outboundSchema, +} from "./subscriberpreferenceoverridedto.js"; +import { + SubscriberPreferencesWorkflowInfoDto, + SubscriberPreferencesWorkflowInfoDto$inboundSchema, + SubscriberPreferencesWorkflowInfoDto$Outbound, + SubscriberPreferencesWorkflowInfoDto$outboundSchema, +} from "./subscriberpreferencesworkflowinfodto.js"; + +export type SubscriberWorkflowPreferenceDto = { + /** + * Whether notifications are enabled for this workflow + */ + enabled: boolean; + /** + * Channel-specific preference settings for this workflow + */ + channels: SubscriberPreferenceChannels; + /** + * List of preference overrides + */ + overrides: Array; + /** + * Workflow information + */ + workflow: SubscriberPreferencesWorkflowInfoDto; +}; + +/** @internal */ +export const SubscriberWorkflowPreferenceDto$inboundSchema: z.ZodType< + SubscriberWorkflowPreferenceDto, + z.ZodTypeDef, + unknown +> = z.object({ + enabled: z.boolean(), + channels: SubscriberPreferenceChannels$inboundSchema, + overrides: z.array(SubscriberPreferenceOverrideDto$inboundSchema), + workflow: SubscriberPreferencesWorkflowInfoDto$inboundSchema, +}); + +/** @internal */ +export type SubscriberWorkflowPreferenceDto$Outbound = { + enabled: boolean; + channels: SubscriberPreferenceChannels$Outbound; + overrides: Array; + workflow: SubscriberPreferencesWorkflowInfoDto$Outbound; +}; + +/** @internal */ +export const SubscriberWorkflowPreferenceDto$outboundSchema: z.ZodType< + SubscriberWorkflowPreferenceDto$Outbound, + z.ZodTypeDef, + SubscriberWorkflowPreferenceDto +> = z.object({ + enabled: z.boolean(), + channels: SubscriberPreferenceChannels$outboundSchema, + overrides: z.array(SubscriberPreferenceOverrideDto$outboundSchema), + workflow: SubscriberPreferencesWorkflowInfoDto$outboundSchema, +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SubscriberWorkflowPreferenceDto$ { + /** @deprecated use `SubscriberWorkflowPreferenceDto$inboundSchema` instead. */ + export const inboundSchema = SubscriberWorkflowPreferenceDto$inboundSchema; + /** @deprecated use `SubscriberWorkflowPreferenceDto$outboundSchema` instead. */ + export const outboundSchema = SubscriberWorkflowPreferenceDto$outboundSchema; + /** @deprecated use `SubscriberWorkflowPreferenceDto$Outbound` instead. */ + export type Outbound = SubscriberWorkflowPreferenceDto$Outbound; +} + +export function subscriberWorkflowPreferenceDtoToJSON( + subscriberWorkflowPreferenceDto: SubscriberWorkflowPreferenceDto, +): string { + return JSON.stringify( + SubscriberWorkflowPreferenceDto$outboundSchema.parse( + subscriberWorkflowPreferenceDto, + ), + ); +} + +export function subscriberWorkflowPreferenceDtoFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SubscriberWorkflowPreferenceDto$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SubscriberWorkflowPreferenceDto' from JSON`, + ); +} diff --git a/src/models/components/timedconfig.ts b/src/models/components/timedconfig.ts index 1cde797d..15330964 100644 --- a/src/models/components/timedconfig.ts +++ b/src/models/components/timedconfig.ts @@ -8,7 +8,7 @@ import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; -export const TimedConfigWeekDays = { +export const WeekDays = { Monday: "monday", Tuesday: "tuesday", Wednesday: "wednesday", @@ -17,7 +17,7 @@ export const TimedConfigWeekDays = { Saturday: "saturday", Sunday: "sunday", } as const; -export type TimedConfigWeekDays = ClosedEnum; +export type WeekDays = ClosedEnum; export const Ordinal = { One: "1", @@ -51,7 +51,7 @@ export type MonthlyType = ClosedEnum; export type TimedConfig = { atTime?: string | undefined; - weekDays?: Array | undefined; + weekDays?: Array | undefined; monthDays?: Array | undefined; ordinal?: Ordinal | undefined; ordinalValue?: OrdinalValue | undefined; @@ -59,24 +59,22 @@ export type TimedConfig = { }; /** @internal */ -export const TimedConfigWeekDays$inboundSchema: z.ZodNativeEnum< - typeof TimedConfigWeekDays -> = z.nativeEnum(TimedConfigWeekDays); +export const WeekDays$inboundSchema: z.ZodNativeEnum = z + .nativeEnum(WeekDays); /** @internal */ -export const TimedConfigWeekDays$outboundSchema: z.ZodNativeEnum< - typeof TimedConfigWeekDays -> = TimedConfigWeekDays$inboundSchema; +export const WeekDays$outboundSchema: z.ZodNativeEnum = + WeekDays$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace TimedConfigWeekDays$ { - /** @deprecated use `TimedConfigWeekDays$inboundSchema` instead. */ - export const inboundSchema = TimedConfigWeekDays$inboundSchema; - /** @deprecated use `TimedConfigWeekDays$outboundSchema` instead. */ - export const outboundSchema = TimedConfigWeekDays$outboundSchema; +export namespace WeekDays$ { + /** @deprecated use `WeekDays$inboundSchema` instead. */ + export const inboundSchema = WeekDays$inboundSchema; + /** @deprecated use `WeekDays$outboundSchema` instead. */ + export const outboundSchema = WeekDays$outboundSchema; } /** @internal */ @@ -143,7 +141,7 @@ export const TimedConfig$inboundSchema: z.ZodType< unknown > = z.object({ atTime: z.string().optional(), - weekDays: z.array(TimedConfigWeekDays$inboundSchema).optional(), + weekDays: z.array(WeekDays$inboundSchema).optional(), monthDays: z.array(z.string()).optional(), ordinal: Ordinal$inboundSchema.optional(), ordinalValue: OrdinalValue$inboundSchema.optional(), @@ -167,7 +165,7 @@ export const TimedConfig$outboundSchema: z.ZodType< TimedConfig > = z.object({ atTime: z.string().optional(), - weekDays: z.array(TimedConfigWeekDays$outboundSchema).optional(), + weekDays: z.array(WeekDays$outboundSchema).optional(), monthDays: z.array(z.string()).optional(), ordinal: Ordinal$outboundSchema.optional(), ordinalValue: OrdinalValue$outboundSchema.optional(), diff --git a/src/models/components/triggereventrequestdto.ts b/src/models/components/triggereventrequestdto.ts index 5737051e..7b4afc88 100644 --- a/src/models/components/triggereventrequestdto.ts +++ b/src/models/components/triggereventrequestdto.ts @@ -7,6 +7,12 @@ import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +import { + StepsOverrides, + StepsOverrides$inboundSchema, + StepsOverrides$Outbound, + StepsOverrides$outboundSchema, +} from "./stepsoverrides.js"; import { SubscriberPayloadDto, SubscriberPayloadDto$inboundSchema, @@ -26,6 +32,50 @@ import { TopicPayloadDto$outboundSchema, } from "./topicpayloaddto.js"; +/** + * This could be used to override provider specific configurations + */ +export type Overrides = { + /** + * This could be used to override provider specific configurations + */ + steps?: { [k: string]: StepsOverrides } | undefined; + /** + * Overrides the provider configuration for the entire workflow and all steps + */ + providers?: { [k: string]: { [k: string]: any } } | undefined; + /** + * Override the email provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + email?: { [k: string]: any } | undefined; + /** + * Override the push provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + push?: { [k: string]: any } | undefined; + /** + * Override the sms provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + sms?: { [k: string]: any } | undefined; + /** + * Override the chat provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + chat?: { [k: string]: any } | undefined; + /** + * Override the layout identifier for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + layoutIdentifier?: string | undefined; +}; + export type One = TopicPayloadDto | SubscriberPayloadDto | string; /** @@ -69,7 +119,7 @@ export type TriggerEventRequestDto = { /** * This could be used to override provider specific configurations */ - overrides?: { [k: string]: { [k: string]: any } } | undefined; + overrides?: Overrides | undefined; /** * The recipients list of people who will receive the notification. */ @@ -98,6 +148,74 @@ export type TriggerEventRequestDto = { tenant?: TenantPayloadDto | string | undefined; }; +/** @internal */ +export const Overrides$inboundSchema: z.ZodType< + Overrides, + z.ZodTypeDef, + unknown +> = z.object({ + steps: z.record(StepsOverrides$inboundSchema).optional(), + providers: z.record(z.record(z.any())).optional(), + email: z.record(z.any()).optional(), + push: z.record(z.any()).optional(), + sms: z.record(z.any()).optional(), + chat: z.record(z.any()).optional(), + layoutIdentifier: z.string().optional(), +}); + +/** @internal */ +export type Overrides$Outbound = { + steps?: { [k: string]: StepsOverrides$Outbound } | undefined; + providers?: { [k: string]: { [k: string]: any } } | undefined; + email?: { [k: string]: any } | undefined; + push?: { [k: string]: any } | undefined; + sms?: { [k: string]: any } | undefined; + chat?: { [k: string]: any } | undefined; + layoutIdentifier?: string | undefined; +}; + +/** @internal */ +export const Overrides$outboundSchema: z.ZodType< + Overrides$Outbound, + z.ZodTypeDef, + Overrides +> = z.object({ + steps: z.record(StepsOverrides$outboundSchema).optional(), + providers: z.record(z.record(z.any())).optional(), + email: z.record(z.any()).optional(), + push: z.record(z.any()).optional(), + sms: z.record(z.any()).optional(), + chat: z.record(z.any()).optional(), + layoutIdentifier: 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 Overrides$ { + /** @deprecated use `Overrides$inboundSchema` instead. */ + export const inboundSchema = Overrides$inboundSchema; + /** @deprecated use `Overrides$outboundSchema` instead. */ + export const outboundSchema = Overrides$outboundSchema; + /** @deprecated use `Overrides$Outbound` instead. */ + export type Outbound = Overrides$Outbound; +} + +export function overridesToJSON(overrides: Overrides): string { + return JSON.stringify(Overrides$outboundSchema.parse(overrides)); +} + +export function overridesFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Overrides$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Overrides' from JSON`, + ); +} + /** @internal */ export const One$inboundSchema: z.ZodType = z.union( [ @@ -301,7 +419,7 @@ export const TriggerEventRequestDto$inboundSchema: z.ZodType< > = z.object({ name: z.string(), payload: z.record(z.any()).optional(), - overrides: z.record(z.record(z.any())).optional(), + overrides: z.lazy(() => Overrides$inboundSchema).optional(), to: z.union([ TopicPayloadDto$inboundSchema, SubscriberPayloadDto$inboundSchema, @@ -327,7 +445,7 @@ export const TriggerEventRequestDto$inboundSchema: z.ZodType< export type TriggerEventRequestDto$Outbound = { name: string; payload?: { [k: string]: any } | undefined; - overrides?: { [k: string]: { [k: string]: any } } | undefined; + overrides?: Overrides$Outbound | undefined; to: | TopicPayloadDto$Outbound | SubscriberPayloadDto$Outbound @@ -346,7 +464,7 @@ export const TriggerEventRequestDto$outboundSchema: z.ZodType< > = z.object({ workflowId: z.string(), payload: z.record(z.any()).optional(), - overrides: z.record(z.record(z.any())).optional(), + overrides: z.lazy(() => Overrides$outboundSchema).optional(), to: z.union([ TopicPayloadDto$outboundSchema, SubscriberPayloadDto$outboundSchema, diff --git a/src/models/components/triggereventtoallrequestdto.ts b/src/models/components/triggereventtoallrequestdto.ts index 3c51b37b..a3b01cde 100644 --- a/src/models/components/triggereventtoallrequestdto.ts +++ b/src/models/components/triggereventtoallrequestdto.ts @@ -3,9 +3,19 @@ */ import * as z from "zod"; -import { safeParse } from "../../lib/schemas.js"; +import { remap as remap$ } from "../../lib/primitives.js"; +import { + collectExtraKeys as collectExtraKeys$, + safeParse, +} from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +import { + StepsOverrides, + StepsOverrides$inboundSchema, + StepsOverrides$Outbound, + StepsOverrides$outboundSchema, +} from "./stepsoverrides.js"; import { SubscriberPayloadDto, SubscriberPayloadDto$inboundSchema, @@ -22,7 +32,47 @@ import { /** * This could be used to override provider specific configurations */ -export type TriggerEventToAllRequestDtoOverrides = {}; +export type TriggerEventToAllRequestDtoOverrides = { + /** + * This could be used to override provider specific configurations + */ + steps?: { [k: string]: StepsOverrides } | undefined; + /** + * Overrides the provider configuration for the entire workflow and all steps + */ + providers?: { [k: string]: { [k: string]: any } } | undefined; + /** + * Override the email provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + email?: { [k: string]: any } | undefined; + /** + * Override the push provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + push?: { [k: string]: any } | undefined; + /** + * Override the sms provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + sms?: { [k: string]: any } | undefined; + /** + * Override the chat provider specific configurations for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + chat?: { [k: string]: any } | undefined; + /** + * Override the layout identifier for the entire workflow + * + * @deprecated field: This will be removed in a future release, please migrate away from it as soon as possible. + */ + layoutIdentifier?: string | undefined; + additionalProperties?: { [k: string]: { [k: string]: any } }; +}; /** * It is used to display the Avatar of the provided actor's subscriber id or actor object. @@ -82,17 +132,54 @@ export const TriggerEventToAllRequestDtoOverrides$inboundSchema: z.ZodType< TriggerEventToAllRequestDtoOverrides, z.ZodTypeDef, unknown -> = z.object({}); +> = collectExtraKeys$( + z.object({ + steps: z.record(StepsOverrides$inboundSchema).optional(), + providers: z.record(z.record(z.any())).optional(), + email: z.record(z.any()).optional(), + push: z.record(z.any()).optional(), + sms: z.record(z.any()).optional(), + chat: z.record(z.any()).optional(), + layoutIdentifier: z.string().optional(), + }).catchall(z.record(z.any())), + "additionalProperties", + true, +); /** @internal */ -export type TriggerEventToAllRequestDtoOverrides$Outbound = {}; +export type TriggerEventToAllRequestDtoOverrides$Outbound = { + steps?: { [k: string]: StepsOverrides$Outbound } | undefined; + providers?: { [k: string]: { [k: string]: any } } | undefined; + email?: { [k: string]: any } | undefined; + push?: { [k: string]: any } | undefined; + sms?: { [k: string]: any } | undefined; + chat?: { [k: string]: any } | undefined; + layoutIdentifier?: string | undefined; + [additionalProperties: string]: unknown; +}; /** @internal */ export const TriggerEventToAllRequestDtoOverrides$outboundSchema: z.ZodType< TriggerEventToAllRequestDtoOverrides$Outbound, z.ZodTypeDef, TriggerEventToAllRequestDtoOverrides -> = z.object({}); +> = z.object({ + steps: z.record(StepsOverrides$outboundSchema).optional(), + providers: z.record(z.record(z.any())).optional(), + email: z.record(z.any()).optional(), + push: z.record(z.any()).optional(), + sms: z.record(z.any()).optional(), + chat: z.record(z.any()).optional(), + layoutIdentifier: z.string().optional(), + additionalProperties: z.record(z.record(z.any())), +}).transform((v) => { + return { + ...v.additionalProperties, + ...remap$(v, { + additionalProperties: null, + }), + }; +}); /** * @internal diff --git a/src/models/components/updatesubscriberchannelrequestdto.ts b/src/models/components/updatesubscriberchannelrequestdto.ts index 92418867..4f9b3ab1 100644 --- a/src/models/components/updatesubscriberchannelrequestdto.ts +++ b/src/models/components/updatesubscriberchannelrequestdto.ts @@ -4,7 +4,6 @@ import * as z from "zod"; import { safeParse } from "../../lib/schemas.js"; -import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { @@ -13,41 +12,17 @@ import { ChannelCredentials$Outbound, ChannelCredentials$outboundSchema, } from "./channelcredentials.js"; - -/** - * The provider identifier for the credentials - */ -export const UpdateSubscriberChannelRequestDtoProviderId = { - Slack: "slack", - Discord: "discord", - Msteams: "msteams", - Mattermost: "mattermost", - Ryver: "ryver", - Zulip: "zulip", - GrafanaOnCall: "grafana-on-call", - Getstream: "getstream", - RocketChat: "rocket-chat", - WhatsappBusiness: "whatsapp-business", - Fcm: "fcm", - Apns: "apns", - Expo: "expo", - OneSignal: "one-signal", - Pushpad: "pushpad", - PushWebhook: "push-webhook", - PusherBeams: "pusher-beams", -} as const; -/** - * The provider identifier for the credentials - */ -export type UpdateSubscriberChannelRequestDtoProviderId = ClosedEnum< - typeof UpdateSubscriberChannelRequestDtoProviderId ->; +import { + ChatOrPushProviderEnum, + ChatOrPushProviderEnum$inboundSchema, + ChatOrPushProviderEnum$outboundSchema, +} from "./chatorpushproviderenum.js"; export type UpdateSubscriberChannelRequestDto = { /** * The provider identifier for the credentials */ - providerId: UpdateSubscriberChannelRequestDtoProviderId; + providerId: ChatOrPushProviderEnum; /** * The integration identifier */ @@ -58,36 +33,13 @@ export type UpdateSubscriberChannelRequestDto = { credentials: ChannelCredentials; }; -/** @internal */ -export const UpdateSubscriberChannelRequestDtoProviderId$inboundSchema: - z.ZodNativeEnum = z - .nativeEnum(UpdateSubscriberChannelRequestDtoProviderId); - -/** @internal */ -export const UpdateSubscriberChannelRequestDtoProviderId$outboundSchema: - z.ZodNativeEnum = - UpdateSubscriberChannelRequestDtoProviderId$inboundSchema; - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace UpdateSubscriberChannelRequestDtoProviderId$ { - /** @deprecated use `UpdateSubscriberChannelRequestDtoProviderId$inboundSchema` instead. */ - export const inboundSchema = - UpdateSubscriberChannelRequestDtoProviderId$inboundSchema; - /** @deprecated use `UpdateSubscriberChannelRequestDtoProviderId$outboundSchema` instead. */ - export const outboundSchema = - UpdateSubscriberChannelRequestDtoProviderId$outboundSchema; -} - /** @internal */ export const UpdateSubscriberChannelRequestDto$inboundSchema: z.ZodType< UpdateSubscriberChannelRequestDto, z.ZodTypeDef, unknown > = z.object({ - providerId: UpdateSubscriberChannelRequestDtoProviderId$inboundSchema, + providerId: ChatOrPushProviderEnum$inboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentials$inboundSchema, }); @@ -105,7 +57,7 @@ export const UpdateSubscriberChannelRequestDto$outboundSchema: z.ZodType< z.ZodTypeDef, UpdateSubscriberChannelRequestDto > = z.object({ - providerId: UpdateSubscriberChannelRequestDtoProviderId$outboundSchema, + providerId: ChatOrPushProviderEnum$outboundSchema, integrationIdentifier: z.string().optional(), credentials: ChannelCredentials$outboundSchema, }); diff --git a/src/models/components/workflowinfodto.ts b/src/models/components/workflowinfodto.ts deleted file mode 100644 index aef00f6d..00000000 --- a/src/models/components/workflowinfodto.ts +++ /dev/null @@ -1,88 +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 WorkflowInfoDto = { - /** - * Workflow slug - */ - slug: string; - /** - * Unique identifier of the workflow - */ - identifier: string; - /** - * Display name of the workflow - */ - name: string; - /** - * last updated date - */ - updatedAt?: string | undefined; -}; - -/** @internal */ -export const WorkflowInfoDto$inboundSchema: z.ZodType< - WorkflowInfoDto, - z.ZodTypeDef, - unknown -> = z.object({ - slug: z.string(), - identifier: z.string(), - name: z.string(), - updatedAt: z.string().optional(), -}); - -/** @internal */ -export type WorkflowInfoDto$Outbound = { - slug: string; - identifier: string; - name: string; - updatedAt?: string | undefined; -}; - -/** @internal */ -export const WorkflowInfoDto$outboundSchema: z.ZodType< - WorkflowInfoDto$Outbound, - z.ZodTypeDef, - WorkflowInfoDto -> = z.object({ - slug: z.string(), - identifier: z.string(), - name: z.string(), - updatedAt: 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 WorkflowInfoDto$ { - /** @deprecated use `WorkflowInfoDto$inboundSchema` instead. */ - export const inboundSchema = WorkflowInfoDto$inboundSchema; - /** @deprecated use `WorkflowInfoDto$outboundSchema` instead. */ - export const outboundSchema = WorkflowInfoDto$outboundSchema; - /** @deprecated use `WorkflowInfoDto$Outbound` instead. */ - export type Outbound = WorkflowInfoDto$Outbound; -} - -export function workflowInfoDtoToJSON( - workflowInfoDto: WorkflowInfoDto, -): string { - return JSON.stringify(WorkflowInfoDto$outboundSchema.parse(workflowInfoDto)); -} - -export function workflowInfoDtoFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => WorkflowInfoDto$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'WorkflowInfoDto' from JSON`, - ); -} diff --git a/src/models/components/workflowpreferencedto.ts b/src/models/components/workflowpreferencedto.ts deleted file mode 100644 index 8b288bff..00000000 --- a/src/models/components/workflowpreferencedto.ts +++ /dev/null @@ -1,108 +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"; -import { - Overrides, - Overrides$inboundSchema, - Overrides$Outbound, - Overrides$outboundSchema, -} from "./overrides.js"; -import { - PreferenceChannels, - PreferenceChannels$inboundSchema, - PreferenceChannels$Outbound, - PreferenceChannels$outboundSchema, -} from "./preferencechannels.js"; -import { - WorkflowInfoDto, - WorkflowInfoDto$inboundSchema, - WorkflowInfoDto$Outbound, - WorkflowInfoDto$outboundSchema, -} from "./workflowinfodto.js"; - -export type WorkflowPreferenceDto = { - /** - * Whether notifications are enabled for this workflow - */ - enabled: boolean; - /** - * Channel-specific preference settings for this workflow - */ - channels: PreferenceChannels; - /** - * List of preference overrides - */ - overrides: Array; - /** - * Workflow information - */ - workflow: WorkflowInfoDto; -}; - -/** @internal */ -export const WorkflowPreferenceDto$inboundSchema: z.ZodType< - WorkflowPreferenceDto, - z.ZodTypeDef, - unknown -> = z.object({ - enabled: z.boolean(), - channels: PreferenceChannels$inboundSchema, - overrides: z.array(Overrides$inboundSchema), - workflow: WorkflowInfoDto$inboundSchema, -}); - -/** @internal */ -export type WorkflowPreferenceDto$Outbound = { - enabled: boolean; - channels: PreferenceChannels$Outbound; - overrides: Array; - workflow: WorkflowInfoDto$Outbound; -}; - -/** @internal */ -export const WorkflowPreferenceDto$outboundSchema: z.ZodType< - WorkflowPreferenceDto$Outbound, - z.ZodTypeDef, - WorkflowPreferenceDto -> = z.object({ - enabled: z.boolean(), - channels: PreferenceChannels$outboundSchema, - overrides: z.array(Overrides$outboundSchema), - workflow: WorkflowInfoDto$outboundSchema, -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace WorkflowPreferenceDto$ { - /** @deprecated use `WorkflowPreferenceDto$inboundSchema` instead. */ - export const inboundSchema = WorkflowPreferenceDto$inboundSchema; - /** @deprecated use `WorkflowPreferenceDto$outboundSchema` instead. */ - export const outboundSchema = WorkflowPreferenceDto$outboundSchema; - /** @deprecated use `WorkflowPreferenceDto$Outbound` instead. */ - export type Outbound = WorkflowPreferenceDto$Outbound; -} - -export function workflowPreferenceDtoToJSON( - workflowPreferenceDto: WorkflowPreferenceDto, -): string { - return JSON.stringify( - WorkflowPreferenceDto$outboundSchema.parse(workflowPreferenceDto), - ); -} - -export function workflowPreferenceDtoFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => WorkflowPreferenceDto$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'WorkflowPreferenceDto' from JSON`, - ); -} diff --git a/src/models/components/workflowresponse.ts b/src/models/components/workflowresponse.ts index 57033369..35e36195 100644 --- a/src/models/components/workflowresponse.ts +++ b/src/models/components/workflowresponse.ts @@ -26,11 +26,11 @@ import { NotificationTrigger$outboundSchema, } from "./notificationtrigger.js"; import { - PreferenceChannels, - PreferenceChannels$inboundSchema, - PreferenceChannels$Outbound, - PreferenceChannels$outboundSchema, -} from "./preferencechannels.js"; + SubscriberPreferenceChannels, + SubscriberPreferenceChannels$inboundSchema, + SubscriberPreferenceChannels$Outbound, + SubscriberPreferenceChannels$outboundSchema, +} from "./subscriberpreferencechannels.js"; export type WorkflowResponseData = {}; @@ -42,7 +42,7 @@ export type WorkflowResponse = { description: string; active: boolean; draft: boolean; - preferenceSettings: PreferenceChannels; + preferenceSettings: SubscriberPreferenceChannels; critical: boolean; tags: Array; steps: Array; @@ -167,7 +167,7 @@ export const WorkflowResponse$inboundSchema: z.ZodType< description: z.string(), active: z.boolean(), draft: z.boolean(), - preferenceSettings: PreferenceChannels$inboundSchema, + preferenceSettings: SubscriberPreferenceChannels$inboundSchema, critical: z.boolean(), tags: z.array(z.string()), steps: z.array(NotificationStepDto$inboundSchema), @@ -203,7 +203,7 @@ export type WorkflowResponse$Outbound = { description: string; active: boolean; draft: boolean; - preferenceSettings: PreferenceChannels$Outbound; + preferenceSettings: SubscriberPreferenceChannels$Outbound; critical: boolean; tags: Array; steps: Array; @@ -232,7 +232,7 @@ export const WorkflowResponse$outboundSchema: z.ZodType< description: z.string(), active: z.boolean(), draft: z.boolean(), - preferenceSettings: PreferenceChannels$outboundSchema, + preferenceSettings: SubscriberPreferenceChannels$outboundSchema, critical: z.boolean(), tags: z.array(z.string()), steps: z.array(NotificationStepDto$outboundSchema), diff --git a/src/models/errors/errordto.ts b/src/models/errors/errordto.ts index c3a34781..26a01feb 100644 --- a/src/models/errors/errordto.ts +++ b/src/models/errors/errordto.ts @@ -3,6 +3,23 @@ */ import * as z from "zod"; +import { safeParse } from "../../lib/schemas.js"; +import { Result as SafeParseResult } from "../../types/fp.js"; +import { SDKValidationError } from "./sdkvalidationerror.js"; + +export type Five = string | number | boolean | { [k: string]: any }; + +export type Four = {}; + +/** + * Value that failed validation + */ +export type Message = + | Four + | string + | number + | boolean + | Array; export type ErrorDtoData = { /** @@ -18,9 +35,16 @@ export type ErrorDtoData = { */ path: string; /** - * A detailed error message. + * Value that failed validation */ - message: string; + message?: + | Four + | string + | number + | boolean + | Array + | null + | undefined; /** * Optional context object for additional error details. */ @@ -79,6 +103,148 @@ export class ErrorDto extends Error { } } +/** @internal */ +export const Five$inboundSchema: z.ZodType = z + .union([z.string(), z.number(), z.boolean(), z.record(z.any())]); + +/** @internal */ +export type Five$Outbound = string | number | boolean | { [k: string]: any }; + +/** @internal */ +export const Five$outboundSchema: z.ZodType = + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Five$ { + /** @deprecated use `Five$inboundSchema` instead. */ + export const inboundSchema = Five$inboundSchema; + /** @deprecated use `Five$outboundSchema` instead. */ + export const outboundSchema = Five$outboundSchema; + /** @deprecated use `Five$Outbound` instead. */ + export type Outbound = Five$Outbound; +} + +export function fiveToJSON(five: Five): string { + return JSON.stringify(Five$outboundSchema.parse(five)); +} + +export function fiveFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Five$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Five' from JSON`, + ); +} + +/** @internal */ +export const Four$inboundSchema: z.ZodType = z + .object({}); + +/** @internal */ +export type Four$Outbound = {}; + +/** @internal */ +export const Four$outboundSchema: z.ZodType = + z.object({}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Four$ { + /** @deprecated use `Four$inboundSchema` instead. */ + export const inboundSchema = Four$inboundSchema; + /** @deprecated use `Four$outboundSchema` instead. */ + export const outboundSchema = Four$outboundSchema; + /** @deprecated use `Four$Outbound` instead. */ + export type Outbound = Four$Outbound; +} + +export function fourToJSON(four: Four): string { + return JSON.stringify(Four$outboundSchema.parse(four)); +} + +export function fourFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Four$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Four' from JSON`, + ); +} + +/** @internal */ +export const Message$inboundSchema: z.ZodType = + z.union([ + z.lazy(() => Four$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]); + +/** @internal */ +export type Message$Outbound = + | Four$Outbound + | string + | number + | boolean + | Array; + +/** @internal */ +export const Message$outboundSchema: z.ZodType< + Message$Outbound, + z.ZodTypeDef, + Message +> = z.union([ + z.lazy(() => Four$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), +]); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Message$ { + /** @deprecated use `Message$inboundSchema` instead. */ + export const inboundSchema = Message$inboundSchema; + /** @deprecated use `Message$outboundSchema` instead. */ + export const outboundSchema = Message$outboundSchema; + /** @deprecated use `Message$Outbound` instead. */ + export type Outbound = Message$Outbound; +} + +export function messageToJSON(message: Message): string { + return JSON.stringify(Message$outboundSchema.parse(message)); +} + +export function messageFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Message$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Message' from JSON`, + ); +} + /** @internal */ export const ErrorDto$inboundSchema: z.ZodType< ErrorDto, @@ -88,7 +254,19 @@ export const ErrorDto$inboundSchema: z.ZodType< statusCode: z.number(), timestamp: z.string(), path: z.string(), - message: z.string(), + message: z.nullable( + z.union([ + z.lazy(() => Four$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), ctx: z.record(z.any()).optional(), errorId: z.string().optional(), }) @@ -101,7 +279,14 @@ export type ErrorDto$Outbound = { statusCode: number; timestamp: string; path: string; - message: string; + message?: + | Four$Outbound + | string + | number + | boolean + | Array + | null + | undefined; ctx?: { [k: string]: any } | undefined; errorId?: string | undefined; }; @@ -117,7 +302,19 @@ export const ErrorDto$outboundSchema: z.ZodType< statusCode: z.number(), timestamp: z.string(), path: z.string(), - message: z.string(), + message: z.nullable( + z.union([ + z.lazy(() => Four$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), ctx: z.record(z.any()).optional(), errorId: z.string().optional(), })); diff --git a/src/models/errors/validationerrordto.ts b/src/models/errors/validationerrordto.ts index 05eaa39e..347b0d33 100644 --- a/src/models/errors/validationerrordto.ts +++ b/src/models/errors/validationerrordto.ts @@ -5,25 +5,22 @@ import * as z from "zod"; import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; +import * as components from "../components/index.js"; import { SDKValidationError } from "./sdkvalidationerror.js"; -export type Value = +export type Message5 = string | number | boolean | { [k: string]: any }; + +export type Message4 = {}; + +/** + * Value that failed validation + */ +export type ValidationErrorDtoMessage = + | Message4 | string | number | boolean - | { [k: string]: any } - | Array<{ [k: string]: any }>; - -export type Errors = { - messages: Array; - value: - | string - | number - | boolean - | { [k: string]: any } - | Array<{ [k: string]: any }> - | null; -}; + | Array; export type ValidationErrorDtoData = { /** @@ -39,9 +36,16 @@ export type ValidationErrorDtoData = { */ path: string; /** - * A detailed error message. + * Value that failed validation */ - message: string; + message?: + | Message4 + | string + | number + | boolean + | Array + | null + | undefined; /** * Optional context object for additional error details. */ @@ -56,7 +60,7 @@ export type ValidationErrorDtoData = { /** * A record of validation errors keyed by field name */ - errors: { [k: string]: Errors }; + errors: { [k: string]: components.ConstraintValidation }; }; export class ValidationErrorDto extends Error { @@ -86,7 +90,7 @@ export class ValidationErrorDto extends Error { /** * A record of validation errors keyed by field name */ - errors: { [k: string]: Errors }; + errors: { [k: string]: components.ConstraintValidation }; /** The original data that was passed to this error instance. */ data$: ValidationErrorDtoData; @@ -110,132 +114,165 @@ export class ValidationErrorDto extends Error { } /** @internal */ -export const Value$inboundSchema: z.ZodType = z - .union([ - z.string(), - z.number(), - z.boolean(), - z.record(z.any()), - z.array(z.record(z.any())), - ]); +export const Message5$inboundSchema: z.ZodType< + Message5, + z.ZodTypeDef, + unknown +> = z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]); /** @internal */ -export type Value$Outbound = - | string - | number - | boolean - | { [k: string]: any } - | Array<{ [k: string]: any }>; +export type Message5$Outbound = string | number | boolean | { + [k: string]: any; +}; /** @internal */ -export const Value$outboundSchema: z.ZodType< - Value$Outbound, +export const Message5$outboundSchema: z.ZodType< + Message5$Outbound, z.ZodTypeDef, - Value -> = z.union([ - z.string(), - z.number(), - z.boolean(), - z.record(z.any()), - z.array(z.record(z.any())), -]); + Message5 +> = z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Value$ { - /** @deprecated use `Value$inboundSchema` instead. */ - export const inboundSchema = Value$inboundSchema; - /** @deprecated use `Value$outboundSchema` instead. */ - export const outboundSchema = Value$outboundSchema; - /** @deprecated use `Value$Outbound` instead. */ - export type Outbound = Value$Outbound; +export namespace Message5$ { + /** @deprecated use `Message5$inboundSchema` instead. */ + export const inboundSchema = Message5$inboundSchema; + /** @deprecated use `Message5$outboundSchema` instead. */ + export const outboundSchema = Message5$outboundSchema; + /** @deprecated use `Message5$Outbound` instead. */ + export type Outbound = Message5$Outbound; } -export function valueToJSON(value: Value): string { - return JSON.stringify(Value$outboundSchema.parse(value)); +export function message5ToJSON(message5: Message5): string { + return JSON.stringify(Message5$outboundSchema.parse(message5)); } -export function valueFromJSON( +export function message5FromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => Value$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'Value' from JSON`, + (x) => Message5$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Message5' from JSON`, ); } /** @internal */ -export const Errors$inboundSchema: z.ZodType = z - .object({ - messages: z.array(z.string()), - value: z.nullable( - z.union([ - z.string(), - z.number(), - z.boolean(), - z.record(z.any()), - z.array(z.record(z.any())), - ]), +export const Message4$inboundSchema: z.ZodType< + Message4, + z.ZodTypeDef, + unknown +> = z.object({}); + +/** @internal */ +export type Message4$Outbound = {}; + +/** @internal */ +export const Message4$outboundSchema: z.ZodType< + Message4$Outbound, + z.ZodTypeDef, + Message4 +> = z.object({}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Message4$ { + /** @deprecated use `Message4$inboundSchema` instead. */ + export const inboundSchema = Message4$inboundSchema; + /** @deprecated use `Message4$outboundSchema` instead. */ + export const outboundSchema = Message4$outboundSchema; + /** @deprecated use `Message4$Outbound` instead. */ + export type Outbound = Message4$Outbound; +} + +export function message4ToJSON(message4: Message4): string { + return JSON.stringify(Message4$outboundSchema.parse(message4)); +} + +export function message4FromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Message4$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Message4' from JSON`, + ); +} + +/** @internal */ +export const ValidationErrorDtoMessage$inboundSchema: z.ZodType< + ValidationErrorDtoMessage, + z.ZodTypeDef, + unknown +> = z.union([ + z.lazy(() => Message4$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), ), - }); + ), +]); /** @internal */ -export type Errors$Outbound = { - messages: Array; - value: - | string - | number - | boolean - | { [k: string]: any } - | Array<{ [k: string]: any }> - | null; -}; +export type ValidationErrorDtoMessage$Outbound = + | Message4$Outbound + | string + | number + | boolean + | Array; /** @internal */ -export const Errors$outboundSchema: z.ZodType< - Errors$Outbound, +export const ValidationErrorDtoMessage$outboundSchema: z.ZodType< + ValidationErrorDtoMessage$Outbound, z.ZodTypeDef, - Errors -> = z.object({ - messages: z.array(z.string()), - value: z.nullable( - z.union([ - z.string(), - z.number(), - z.boolean(), - z.record(z.any()), - z.array(z.record(z.any())), - ]), + ValidationErrorDtoMessage +> = z.union([ + z.lazy(() => Message4$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), ), -}); +]); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ -export namespace Errors$ { - /** @deprecated use `Errors$inboundSchema` instead. */ - export const inboundSchema = Errors$inboundSchema; - /** @deprecated use `Errors$outboundSchema` instead. */ - export const outboundSchema = Errors$outboundSchema; - /** @deprecated use `Errors$Outbound` instead. */ - export type Outbound = Errors$Outbound; +export namespace ValidationErrorDtoMessage$ { + /** @deprecated use `ValidationErrorDtoMessage$inboundSchema` instead. */ + export const inboundSchema = ValidationErrorDtoMessage$inboundSchema; + /** @deprecated use `ValidationErrorDtoMessage$outboundSchema` instead. */ + export const outboundSchema = ValidationErrorDtoMessage$outboundSchema; + /** @deprecated use `ValidationErrorDtoMessage$Outbound` instead. */ + export type Outbound = ValidationErrorDtoMessage$Outbound; } -export function errorsToJSON(errors: Errors): string { - return JSON.stringify(Errors$outboundSchema.parse(errors)); +export function validationErrorDtoMessageToJSON( + validationErrorDtoMessage: ValidationErrorDtoMessage, +): string { + return JSON.stringify( + ValidationErrorDtoMessage$outboundSchema.parse(validationErrorDtoMessage), + ); } -export function errorsFromJSON( +export function validationErrorDtoMessageFromJSON( jsonString: string, -): SafeParseResult { +): SafeParseResult { return safeParse( jsonString, - (x) => Errors$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'Errors' from JSON`, + (x) => ValidationErrorDtoMessage$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'ValidationErrorDtoMessage' from JSON`, ); } @@ -248,10 +285,22 @@ export const ValidationErrorDto$inboundSchema: z.ZodType< statusCode: z.number(), timestamp: z.string(), path: z.string(), - message: z.string(), + message: z.nullable( + z.union([ + z.lazy(() => Message4$inboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), ctx: z.record(z.any()).optional(), errorId: z.string().optional(), - errors: z.record(z.lazy(() => Errors$inboundSchema)), + errors: z.record(components.ConstraintValidation$inboundSchema), }) .transform((v) => { return new ValidationErrorDto(v); @@ -262,10 +311,17 @@ export type ValidationErrorDto$Outbound = { statusCode: number; timestamp: string; path: string; - message: string; + message?: + | Message4$Outbound + | string + | number + | boolean + | Array + | null + | undefined; ctx?: { [k: string]: any } | undefined; errorId?: string | undefined; - errors: { [k: string]: Errors$Outbound }; + errors: { [k: string]: components.ConstraintValidation$Outbound }; }; /** @internal */ @@ -279,10 +335,22 @@ export const ValidationErrorDto$outboundSchema: z.ZodType< statusCode: z.number(), timestamp: z.string(), path: z.string(), - message: z.string(), + message: z.nullable( + z.union([ + z.lazy(() => Message4$outboundSchema), + z.string(), + z.number(), + z.boolean(), + z.array( + z.nullable( + z.union([z.string(), z.number(), z.boolean(), z.record(z.any())]), + ), + ), + ]), + ).optional(), ctx: z.record(z.any()).optional(), errorId: z.string().optional(), - errors: z.record(z.lazy(() => Errors$outboundSchema)), + errors: z.record(components.ConstraintValidation$outboundSchema), })); /** diff --git a/src/models/operations/messagescontrollergetmessages.ts b/src/models/operations/messagescontrollergetmessages.ts index 73235935..deec8d3d 100644 --- a/src/models/operations/messagescontrollergetmessages.ts +++ b/src/models/operations/messagescontrollergetmessages.ts @@ -26,7 +26,7 @@ export type MessagesControllerGetMessagesRequest = { export type MessagesControllerGetMessagesResponse = { headers: { [k: string]: Array }; - result: components.ActivitiesResponseDto; + result: components.MessagesResponseDto; }; /** @internal */ @@ -118,7 +118,7 @@ export const MessagesControllerGetMessagesResponse$inboundSchema: z.ZodType< unknown > = z.object({ Headers: z.record(z.array(z.string())), - Result: components.ActivitiesResponseDto$inboundSchema, + Result: components.MessagesResponseDto$inboundSchema, }).transform((v) => { return remap$(v, { "Headers": "headers", @@ -129,7 +129,7 @@ export const MessagesControllerGetMessagesResponse$inboundSchema: z.ZodType< /** @internal */ export type MessagesControllerGetMessagesResponse$Outbound = { Headers: { [k: string]: Array }; - Result: components.ActivitiesResponseDto$Outbound; + Result: components.MessagesResponseDto$Outbound; }; /** @internal */ @@ -139,7 +139,7 @@ export const MessagesControllerGetMessagesResponse$outboundSchema: z.ZodType< MessagesControllerGetMessagesResponse > = z.object({ headers: z.record(z.array(z.string())), - result: components.ActivitiesResponseDto$outboundSchema, + result: components.MessagesResponseDto$outboundSchema, }).transform((v) => { return remap$(v, { headers: "Headers", From 08761287b7255165e2020c8be5139a2d345737d0 Mon Sep 17 00:00:00 2001 From: "speakeasy-github[bot]" <128539517+speakeasy-github[bot]@users.noreply.github.com> Date: Thu, 8 May 2025 00:21:06 +0000 Subject: [PATCH 2/2] empty commit to trigger [run-tests] workflow