From 0e7ef8bdea295f1703addad2480adc7474058845 Mon Sep 17 00:00:00 2001 From: speakeasybot Date: Tue, 23 Jul 2024 00:25:25 +0000 Subject: [PATCH] ci: regenerated with Speakeasy CLI v1.345.1 --- .speakeasy/workflow.lock | 8 +- openapi.json | 15522 ++++++++++++++++--------------------- 2 files changed, 6621 insertions(+), 8909 deletions(-) diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index 0fd49460..9234ce99 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,12 +1,12 @@ -speakeasyVersion: 1.308.1 +speakeasyVersion: 1.345.1 sources: openapi-with-code-samples: sourceNamespace: openapi-with-code-samples - sourceRevisionDigest: sha256:8e7b0030b71fdec4ccecd24cc1bc1969ef382cc2ac80a11c3c813ccedf287388 - sourceBlobDigest: sha256:b1f491e8f7b893a82300669ad821fa6c249c74874cae1213c92719b423d5457f + sourceRevisionDigest: sha256:e4a4ea7ad27d3d6010e5f462c809d8474c8fdcc6ac9a005a541239f804bc43c0 + sourceBlobDigest: sha256:3178fce8e62d01ab8aa103d07e46338807bb70460fd7e51b8dc55bfe6709fb43 tags: - latest - - staging + - main targets: {} workflow: workflowVersion: 1.0.0 diff --git a/openapi.json b/openapi.json index 52969393..984c7a44 100644 --- a/openapi.json +++ b/openapi.json @@ -1,8905 +1,6617 @@ -{ - "openapi": "3.0.0", - "paths": { - "/v1/organizations": { - "post": { - "operationId": "OrganizationController_createOrganization", - "summary": "Create an organization", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/CreateOrganizationDto" } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/OrganizationResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_createOrganization", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "OrganizationController_listOrganizations", - "summary": "Fetch all organizations", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/OrganizationResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_listOrganizations", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "OrganizationController_rename", - "x-speakeasy-name-override": "rename", - "summary": "Rename organization name", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/RenameOrganizationDto" } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RenameOrganizationDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_rename", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.rename({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/organizations/me": { - "get": { - "operationId": "OrganizationController_getSelfOrganizationData", - "summary": "Fetch current organization details", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/OrganizationResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_getSelfOrganizationData", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/organizations/members/{memberId}": { - "delete": { - "operationId": "OrganizationController_remove", - "x-speakeasy-group": "Organizations.Members", - "summary": "Remove a member from organization using memberId", - "parameters": [ - { - "name": "memberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/MemberResponseDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_remove", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.members.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/organizations/members": { - "get": { - "operationId": "OrganizationController_listOrganizationMembers", - "x-speakeasy-group": "Organizations.Members", - "summary": "Fetch all members of current organizations", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/MemberResponseDto" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_listOrganizationMembers", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.members.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/organizations/branding": { - "put": { - "operationId": "OrganizationController_updateBrandingDetails", - "x-speakeasy-group": "Organizations.Branding", - "summary": "Update organization branding details", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateBrandingDetailsDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/OrganizationBrandingResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Organizations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "OrganizationController_updateBrandingDetails", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.branding.update({\n logo: \"\",\n color: \"fuchsia\",\n fontColor: \"\",\n contentBackground: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/environments/me": { - "get": { - "operationId": "EnvironmentsController_getCurrentEnvironment", - "summary": "Get current environment", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/EnvironmentResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Environments"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EnvironmentsController_getCurrentEnvironment", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/environments": { - "get": { - "operationId": "EnvironmentsController_listMyEnvironments", - "summary": "Get environments", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/EnvironmentResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Environments"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EnvironmentsController_listMyEnvironments", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/environments/api-keys": { - "get": { - "operationId": "EnvironmentsController_listOrganizationApiKeys", - "x-speakeasy-group": "Environments.ApiKeys", - "summary": "Get api keys", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/ApiKey" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Environments"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EnvironmentsController_listOrganizationApiKeys", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.apiKeys.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/environments/api-keys/regenerate": { - "post": { - "operationId": "EnvironmentsController_regenerateOrganizationApiKeys", - "x-speakeasy-name-override": "regenerate", - "x-speakeasy-group": "Environments.ApiKeys", - "summary": "Regenerate api keys", - "parameters": [], - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/ApiKey" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Environments"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EnvironmentsController_regenerateOrganizationApiKeys", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.apiKeys.regenerate();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/execution-details": { - "get": { - "operationId": "ExecutionDetailsController_getExecutionDetailsForNotification", - "summary": "Get execution details", - "parameters": [ - { - "name": "notificationId", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "subscriberId", - "required": true, - "in": "query", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ExecutionDetailsResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Execution Details"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "ExecutionDetailsController_getExecutionDetailsForNotification", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.executionDetails.retrieve(\"\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/workflows": { - "get": { - "operationId": "WorkflowController_listWorkflows", - "summary": "Get workflows", - "description": "Workflows were previously named notification templates", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "schema": { "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "maximum": 100, "default": 10, "type": "number" } - }, - { - "name": "query", - "required": false, - "in": "query", - "description": "A query string to filter the results. It allows filtering based on either the name or trigger identifier of the workflow items.", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/WorkflowsResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_listWorkflows", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.list({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "post": { - "operationId": "WorkflowController_create", - "summary": "Create workflow", - "description": "Workflow was previously named notification template", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateWorkflowRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/WorkflowResponse" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_create", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.create({\n name: \"\",\n notificationGroupId: \"\",\n steps: [\n {},\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/workflows/{workflowId}": { - "put": { - "operationId": "WorkflowController_updateWorkflowById", - "summary": "Update workflow", - "description": "Workflow was previously named notification template", - "parameters": [ - { - "name": "workflowId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateWorkflowRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/WorkflowResponse" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_updateWorkflowById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.update(\"\", {\n name: \"\",\n notificationGroupId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "WorkflowController_deleteWorkflowById", - "summary": "Delete workflow", - "description": "Workflow was previously named notification template", - "parameters": [ - { - "name": "workflowId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/DataBooleanDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_deleteWorkflowById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "WorkflowController_getWorkflowById", - "summary": "Get workflow", - "description": "Workflow was previously named notification template", - "parameters": [ - { - "name": "workflowId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/WorkflowResponse" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_getWorkflowById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/workflows/variables": { - "get": { - "operationId": "WorkflowController_getWorkflowVariables", - "x-speakeasy-group": "Workflows.Variables", - "summary": "Get available variables", - "description": "Get the variables that can be used in the workflow", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/VariablesResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_getWorkflowVariables", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.variables.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/workflows/{workflowId}/status": { - "put": { - "operationId": "WorkflowController_updateActiveStatus", - "x-speakeasy-group": "Workflows.Status", - "summary": "Update workflow status", - "description": "Workflow was previously named notification template", - "parameters": [ - { - "name": "workflowId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ChangeWorkflowStatusRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/WorkflowResponse" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflows"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "WorkflowController_updateActiveStatus", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.status.update(\"\", {\n active: false,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/events/trigger": { - "post": { - "operationId": "EventsController_trigger", - "x-speakeasy-group": "", - "x-speakeasy-usage-example": { "title": "Trigger Notification Event" }, - "x-speakeasy-name-override": "trigger", - "summary": "Trigger event", - "description": "\n Trigger event is the main (and only) way to send notifications to subscribers. \n The trigger identifier is used to match the particular workflow associated with it. \n Additional information can be passed according the body interface below.\n ", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TriggerEventRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TriggerEventResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Events"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EventsController_trigger", - "source": "import { Novu } from \"@novu/api\";\nimport { TopicPayloadDtoType } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.trigger({\n name: \"workflow_identifier\",\n payload: {},\n overrides: {},\n to: [\n {\n topicKey: \"topic_key\",\n type: TopicPayloadDtoType.Topic,\n },\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/events/trigger/bulk": { - "post": { - "operationId": "EventsController_triggerBulk", - "x-speakeasy-name-override": "triggerBulk", - "summary": "Bulk trigger event", - "description": "\n Using this endpoint you can trigger multiple events at once, to avoid multiple calls to the API.\n The bulk API is limited to 100 events per request.\n ", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/BulkTriggerEventDto" } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/TriggerEventResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Events"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EventsController_triggerBulk", - "source": "import { Novu } from \"@novu/api\";\nimport { TopicPayloadDtoType } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.events.triggerBulk({\n events: [\n {\n name: \"workflow_identifier\",\n payload: {},\n overrides: {},\n to: [\n {\n topicKey: \"topic_key\",\n type: TopicPayloadDtoType.Topic,\n },\n ],\n },\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/events/trigger/broadcast": { - "post": { - "operationId": "EventsController_broadcastEventToAll", - "x-speakeasy-name-override": "triggerBroadcast", - "summary": "Broadcast event to all", - "description": "Trigger a broadcast event to all existing subscribers, could be used to send announcements, etc.\n In the future could be used to trigger events to a subset of subscribers based on defined filters.", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TriggerEventToAllRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TriggerEventResponseDto" - } - } - } - }, - "201": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/TriggerEventResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Events"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EventsController_broadcastEventToAll", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.events.triggerBroadcast({\n name: \"\",\n payload: {},\n overrides: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/events/trigger/{transactionId}": { - "delete": { - "operationId": "EventsController_cancel", - "x-speakeasy-name-override": "cancel", - "summary": "Cancel triggered event", - "description": "\n Using a previously generated transactionId during the event trigger,\n will cancel any active or pending workflows. This is useful to cancel active digests, delays etc...\n ", - "parameters": [ - { - "name": "transactionId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/DataBooleanDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Events"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "EventsController_cancel", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.events.cancel(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notifications": { - "get": { - "operationId": "NotificationsController_listNotifications", - "summary": "Get notifications", - "parameters": [ - { - "name": "channels", - "required": true, - "in": "query", - "schema": { - "type": "array", - "items": { - "type": "string", - "enum": ["in_app", "email", "sms", "chat", "push"] - } - } - }, - { - "name": "templates", - "required": true, - "in": "query", - "schema": { "type": "array", "items": { "type": "string" } } - }, - { - "name": "emails", - "required": true, - "in": "query", - "schema": { "type": "array", "items": { "type": "string" } } - }, - { - "name": "search", - "required": true, - "in": "query", - "deprecated": true, - "schema": { "type": "string" } - }, - { - "name": "subscriberIds", - "required": true, - "in": "query", - "schema": { "type": "array", "items": { "type": "string" } } - }, - { - "name": "page", - "required": false, - "in": "query", - "schema": { "default": 0, "type": "number" } - }, - { - "name": "transactionId", - "required": false, - "in": "query", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ActivitiesResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Notifications"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationsController_listNotifications", - "source": "import { Novu } from \"@novu/api\";\nimport { Channels } from \"@novu/api/models/operations\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.list({\n channels: [\n Channels.Chat,\n ],\n templates: [\n \"\",\n ],\n emails: [\n \"\",\n ],\n search: \"\",\n subscriberIds: [\n \"\",\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notifications/stats": { - "get": { - "operationId": "NotificationsController_getActivityStats", - "x-speakeasy-group": "Notifications.Stats", - "summary": "Get notification statistics", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ActivityStatsResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Notifications"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationsController_getActivityStats", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.stats.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notifications/graph/stats": { - "get": { - "operationId": "NotificationsController_getActivityGraphStats", - "x-speakeasy-name-override": "graph", - "x-speakeasy-group": "Notifications.Stats", - "summary": "Get notification graph statistics", - "parameters": [ - { - "name": "days", - "required": false, - "in": "query", - "schema": { "type": "number" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ActivityGraphStatesResponse" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Notifications"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationsController_getActivityGraphStats", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.stats.graph(4018.61);\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notifications/{notificationId}": { - "get": { - "operationId": "NotificationsController_getNotification", - "summary": "Get notification", - "parameters": [ - { - "name": "notificationId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ActivityNotificationResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Notifications"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationsController_getNotification", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notification-groups": { - "post": { - "operationId": "NotificationGroupsController_createNotificationGroup", - "summary": "Create workflow group", - "description": "workflow group was previously named notification group", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateNotificationGroupRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/NotificationGroupResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflow groups"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationGroupsController_createNotificationGroup", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "NotificationGroupsController_listNotificationGroups", - "summary": "Get workflow groups", - "description": "workflow group was previously named notification group", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationGroupResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflow groups"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationGroupsController_listNotificationGroups", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/notification-groups/{id}": { - "get": { - "operationId": "NotificationGroupsController_getNotificationGroup", - "summary": "Get workflow group", - "description": "workflow group was previously named notification group", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/NotificationGroupResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflow groups"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationGroupsController_getNotificationGroup", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "NotificationGroupsController_updateNotificationGroup", - "summary": "Update workflow group", - "description": "workflow group was previously named notification group", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateNotificationGroupRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/NotificationGroupResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflow groups"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationGroupsController_updateNotificationGroup", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.update(\"\", {\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "NotificationGroupsController_deleteNotificationGroup", - "summary": "Delete workflow group", - "description": "workflow group was previously named notification group", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteNotificationGroupResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Workflow groups"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "NotificationGroupsController_deleteNotificationGroup", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/integrations": { - "get": { - "operationId": "IntegrationsController_listIntegrations", - "summary": "Get integrations", - "description": "Return all the integrations the user has created for that organization. Review v.0.17.0 changelog for a breaking change", - "parameters": [], - "responses": { - "200": { - "description": "The list of integrations belonging to the organization that are successfully returned.", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_listIntegrations", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "post": { - "operationId": "IntegrationsController_createIntegration", - "summary": "Create integration", - "description": "Create an integration for the current environment the user is based on the API key provided", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateIntegrationRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_createIntegration", - "source": "import { Novu } from \"@novu/api\";\nimport { CreateIntegrationRequestDtoChannel } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.create({\n providerId: \"\",\n channel: CreateIntegrationRequestDtoChannel.Sms,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/integrations/active": { - "get": { - "operationId": "IntegrationsController_getActiveIntegrations", - "x-speakeasy-name-override": "listActive", - "summary": "Get active integrations", - "description": "Return all the active integrations the user has created for that organization. Review v.0.17.0 changelog for a breaking change", - "parameters": [], - "responses": { - "200": { - "description": "The list of active integrations belonging to the organization that are successfully returned.", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_getActiveIntegrations", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.listActive();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/integrations/webhook/provider/{providerOrIntegrationId}/status": { - "get": { - "operationId": "IntegrationsController_getWebhookSupportStatus", - "x-speakeasy-group": "Integrations.Webhooks", - "summary": "Get webhook support status for provider", - "description": "Return the status of the webhook for this provider, if it is supported or if it is not based on a boolean value", - "parameters": [ - { - "name": "providerOrIntegrationId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "The status of the webhook for the provider requested", - "content": { - "application/json": { "schema": { "type": "boolean" } } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_getWebhookSupportStatus", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.webhooks.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/integrations/{integrationId}": { - "put": { - "operationId": "IntegrationsController_updateIntegrationById", - "summary": "Update integration", - "parameters": [ - { - "name": "integrationId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateIntegrationRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - }, - "404": { - "description": "The integration with the integrationId provided does not exist in the database." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_updateIntegrationById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "IntegrationsController_removeIntegration", - "summary": "Delete integration", - "parameters": [ - { - "name": "integrationId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_removeIntegration", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/integrations/{integrationId}/set-primary": { - "post": { - "operationId": "IntegrationsController_setIntegrationAsPrimary", - "x-speakeasy-name-override": "setAsPrimary", - "summary": "Set integration as primary", - "parameters": [ - { - "name": "integrationId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - }, - "201": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IntegrationResponseDto" - } - } - } - }, - "404": { - "description": "The integration with the integrationId provided does not exist in the database." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Integrations"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "IntegrationsController_setIntegrationAsPrimary", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.setAsPrimary(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/changes": { - "get": { - "operationId": "ChangesController_getChanges", - "summary": "Get changes", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "schema": { "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "maximum": 100, "default": 10, "type": "number" } - }, - { - "name": "promoted", - "required": true, - "in": "query", - "schema": { "default": "false", "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/ChangesResponseDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Changes"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "ChangesController_getChanges", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.retrieve({\n promoted: \"false\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/changes/count": { - "get": { - "operationId": "ChangesController_getChangesCount", - "x-speakeasy-name-override": "count", - "summary": "Get changes count", - "parameters": [], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/DataNumberDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Changes"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "ChangesController_getChangesCount", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.count();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/changes/bulk/apply": { - "post": { - "operationId": "ChangesController_bulkApplyDiff", - "x-speakeasy-name-override": "applyBulk", - "summary": "Apply changes", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/BulkApplyChangeDto" } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/ChangeResponseDto" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Changes"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "ChangesController_bulkApplyDiff", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.applyBulk({\n changeIds: [\n \"\",\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/changes/{changeId}/apply": { - "post": { - "operationId": "ChangesController_applyDiff", - "x-speakeasy-name-override": "apply", - "summary": "Apply change", - "parameters": [ - { - "name": "changeId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/ChangeResponseDto" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Changes"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "ChangesController_applyDiff", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.apply(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers": { - "get": { - "operationId": "SubscribersController_listSubscribers", - "x-speakeasy-pagination": { - "type": "offsetLimit", - "inputs": [ - { "name": "page", "in": "parameters", "type": "page" }, - { "name": "limit", "in": "parameters", "type": "limit" } - ], - "outputs": { "results": "$.data.resultArray" } - }, - "summary": "Get subscribers", - "description": "Returns a list of subscribers, could paginated using the `page` and `limit` query parameter", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "schema": { "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "maximum": 100, "default": 10, "type": "number" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "allOf": [ - { "$ref": "#/components/schemas/PaginatedResponseDto" }, - { - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - } - ] - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_listSubscribers", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.list(7685.78, 10);\n\n for await (const page of result) {\n // handle page\n }\n}\n\nrun();" - } - ] - }, - "post": { - "operationId": "SubscribersController_createSubscriber", - "summary": "Create subscriber", - "description": "Creates a subscriber entity, in the Novu platform. The subscriber will be later used to receive notifications, and access notification feeds. Communication credentials such as email, phone number, and 3 rd party credentials i.e slack tokens could be later associated to this entity.", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateSubscriberRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_createSubscriber", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.create({\n subscriberId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}": { - "get": { - "operationId": "SubscribersController_getSubscriber", - "summary": "Get subscriber", - "description": "Get subscriber by your internal id used to identify the subscriber", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_getSubscriber", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "put": { - "operationId": "SubscribersController_updateSubscriber", - "summary": "Update subscriber", - "description": "Used to update the subscriber entity with new information", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_updateSubscriber", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "SubscribersController_removeSubscriber", - "summary": "Delete subscriber", - "description": "Deletes a subscriber entity from the Novu platform", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteSubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_removeSubscriber", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/bulk": { - "post": { - "operationId": "SubscribersController_bulkCreateSubscribers", - "x-speakeasy-name-override": "createBulk", - "summary": "Bulk create subscribers", - "description": "\n Using this endpoint you can create multiple subscribers at once, to avoid multiple calls to the API.\n The bulk API is limited to 500 subscribers per request.\n ", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/BulkSubscriberCreateDto" - } - } - } - }, - "responses": { - "201": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_bulkCreateSubscribers", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.createBulk({\n subscribers: [\n {\n subscriberId: \"\",\n },\n ],\n });\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/credentials": { - "put": { - "operationId": "SubscribersController_updateSubscriberChannel", - "x-speakeasy-group": "Subscribers.Credentials", - "summary": "Update subscriber credentials", - "description": "Subscriber credentials associated to the delivery methods such as slack and push tokens.", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberChannelRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_updateSubscriberChannel", - "source": "import { Novu } from \"@novu/api\";\nimport { UpdateSubscriberChannelRequestDtoProviderId } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.credentials.update(\"\", {\n providerId: UpdateSubscriberChannelRequestDtoProviderId.Pushpad,\n credentials: {\n webhookUrl: \"\",\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "SubscribersController_modifySubscriberChannel", - "x-speakeasy-name-override": "append", - "x-speakeasy-group": "Subscribers.Credentials", - "summary": "Modify subscriber credentials", - "description": "Subscriber credentials associated to the delivery methods such as slack and push tokens.\n This endpoint appends provided credentials and deviceTokens to the existing ones.", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberChannelRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_modifySubscriberChannel", - "source": "import { Novu } from \"@novu/api\";\nimport { UpdateSubscriberChannelRequestDtoProviderId } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.credentials.append(\"\", {\n providerId: UpdateSubscriberChannelRequestDtoProviderId.Zulip,\n credentials: {\n webhookUrl: \"\",\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/credentials/{providerId}": { - "delete": { - "operationId": "SubscribersController_deleteSubscriberCredentials", - "x-speakeasy-group": "Subscribers.Credentials", - "summary": "Delete subscriber credentials by providerId", - "description": "Delete subscriber credentials such as slack and expo tokens.", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "providerId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_deleteSubscriberCredentials", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.credentials.delete(\"\", \"\");\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/online-status": { - "patch": { - "operationId": "SubscribersController_updateSubscriberOnlineFlag", - "x-speakeasy-name-override": "updateOnlineFlag", - "x-speakeasy-group": "Subscribers.properties", - "summary": "Update subscriber online status", - "description": "Used to update the subscriber isOnline flag.", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberOnlineFlagRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/SubscriberResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_updateSubscriberOnlineFlag", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.properties.updateOnlineFlag(\"\", {\n isOnline: false,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/preferences": { - "get": { - "operationId": "SubscribersController_listSubscriberPreferences", - "x-speakeasy-group": "Subscribers.Preferences", - "summary": "Get subscriber preferences", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_listSubscriberPreferences", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.list(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "SubscribersController_updateSubscriberGlobalPreferences", - "x-speakeasy-name-override": "updateGlobal", - "x-speakeasy-group": "Subscribers.Preferences", - "summary": "Update subscriber global preferences", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberGlobalPreferencesRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_updateSubscriberGlobalPreferences", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.updateGlobal(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/preferences/{parameter}": { - "get": { - "operationId": "SubscribersController_getSubscriberPreferenceByLevel", - "x-speakeasy-name-override": "retrieveByLevel", - "x-speakeasy-group": "Subscribers.Preferences", - "summary": "Get subscriber preferences by level", - "parameters": [ - { - "name": "parameter", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetSubscriberPreferencesResponseDto" - } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_getSubscriberPreferenceByLevel", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.retrieveByLevel(\"\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "SubscribersController_updateSubscriberPreference", - "x-speakeasy-group": "Subscribers.Preferences", - "summary": "Update subscriber preference", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "parameter", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberPreferenceRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_updateSubscriberPreference", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.update({\n subscriberId: \"\",\n parameter: \"\",\n updateSubscriberPreferenceRequestDto: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/notifications/feed": { - "get": { - "operationId": "SubscribersController_getNotificationsFeed", - "x-speakeasy-group": "Subscribers.Notifications", - "summary": "Get in-app notification feed for a particular subscriber", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "page", - "required": false, - "in": "query", - "schema": { "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "maximum": 100, "default": 10, "type": "number" } - }, - { - "name": "read", - "required": false, - "in": "query", - "schema": { "type": "boolean" } - }, - { - "name": "seen", - "required": false, - "in": "query", - "schema": { "type": "boolean" } - }, - { - "name": "payload", - "required": false, - "in": "query", - "description": "Base64 encoded string of the partial payload JSON object", - "example": "btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "allOf": [ - { "$ref": "#/components/schemas/PaginatedResponseDto" }, - { - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/FeedResponseDto" - } - } - } - } - ] - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_getNotificationsFeed", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.notifications.retrieve({\n subscriberId: \"\",\n payload: \"btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/notifications/unseen": { - "get": { - "operationId": "SubscribersController_getUnseenCount", - "x-speakeasy-name-override": "unseenCount", - "x-speakeasy-group": "Subscribers.Notifications", - "summary": "Get the unseen in-app notifications count for subscribers feed", - "parameters": [ - { - "name": "seen", - "required": true, - "in": "query", - "schema": { "type": "boolean" } - }, - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "limit", - "required": true, - "in": "query", - "schema": { "type": "number" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/UnseenCountResponse" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_getUnseenCount", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.notifications.unseenCount({\n seen: false,\n subscriberId: \"\",\n limit: 2166.35,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/messages/mark-as": { - "post": { - "operationId": "SubscribersController_markMessagesAs", - "x-speakeasy-name-override": "markAllAs", - "x-speakeasy-group": "Subscribers.Messages", - "summary": "Mark a subscriber messages as seen, read, unseen or unread", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/MessageMarkAsRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/MessageEntity" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_markMessagesAs", - "source": "import { Novu } from \"@novu/api\";\nimport { MarkAs } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.markAllAs(\"\", {\n messageId: \"\",\n markAs: MarkAs.Seen,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/messages/mark-all": { - "post": { - "operationId": "SubscribersController_markAllUnreadAsRead", - "x-speakeasy-name-override": "markAll", - "x-speakeasy-group": "Subscribers.Messages", - "summary": "Marks all the subscriber messages as read, unread, seen or unseen. Optionally you can pass feed id (or array) to mark messages of a particular feed.", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/MarkAllMessageAsRequestDto" - } - } - } - }, - "responses": { - "201": { - "description": "", - "content": { - "application/json": { "schema": { "type": "number" } } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_markAllUnreadAsRead", - "source": "import { Novu } from \"@novu/api\";\nimport { MarkAllMessageAsRequestDtoMarkAs } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.markAll(\"\", {\n markAs: MarkAllMessageAsRequestDtoMarkAs.Seen,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/messages/{messageId}/actions/{type}": { - "post": { - "operationId": "SubscribersController_markActionAsSeen", - "x-speakeasy-name-override": "updateAsSeen", - "x-speakeasy-group": "Subscribers.Messages", - "summary": "Mark message action as seen", - "parameters": [ - { - "name": "messageId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "type", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/MarkMessageActionAsSeenDto" - } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/MessageResponseDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_markActionAsSeen", - "source": "import { Novu } from \"@novu/api\";\nimport { MarkMessageActionAsSeenDtoStatus } from \"@novu/api/models/components\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.updateAsSeen({\n messageId: \"\",\n type: \"\",\n subscriberId: \"\",\n markMessageActionAsSeenDto: {\n status: MarkMessageActionAsSeenDtoStatus.Done,\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/credentials/{providerId}/oauth/callback": { - "get": { - "operationId": "SubscribersController_chatOauthCallback", - "x-speakeasy-name-override": "chatAccessOauthCallBack", - "x-speakeasy-group": "Subscribers.Authentication", - "summary": "Handle providers oauth redirect", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "providerId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "code", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "hmacHash", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "environmentId", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "integrationIdentifier", - "required": false, - "in": "query", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { "schema": { "type": "object" } } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_chatOauthCallback", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.authentication.chatAccessOauthCallBack({\n subscriberId: \"\",\n providerId: \"\",\n code: \"\",\n hmacHash: \"\",\n environmentId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/subscribers/{subscriberId}/credentials/{providerId}/oauth": { - "get": { - "operationId": "SubscribersController_chatAccessOauth", - "x-speakeasy-name-override": "chatAccessOauth", - "x-speakeasy-group": "Subscribers.Authentication", - "summary": "Handle chat oauth", - "parameters": [ - { - "name": "subscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "providerId", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "hmacHash", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "environmentId", - "required": true, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "integrationIdentifier", - "required": false, - "in": "query", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Subscribers"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "SubscribersController_chatAccessOauth", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.authentication.chatAccessOauth({\n subscriberId: \"\",\n providerId: \"\",\n hmacHash: \"\",\n environmentId: \"\",\n });\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/feeds": { - "post": { - "operationId": "FeedsController_createFeed", - "summary": "Create feed", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/CreateFeedRequestDto" } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/FeedResponseDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Feeds"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "FeedsController_createFeed", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "FeedsController_getFeeds", - "summary": "Get feeds", - "parameters": [], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/FeedResponseDto" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Feeds"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "FeedsController_getFeeds", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/feeds/{feedId}": { - "delete": { - "operationId": "FeedsController_deleteFeedById", - "summary": "Delete feed", - "parameters": [ - { - "name": "feedId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "type": "array", - "items": { "$ref": "#/components/schemas/FeedResponseDto" } - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Feeds"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "FeedsController_deleteFeedById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/layouts": { - "post": { - "operationId": "LayoutsController_PropertyDescriptor", - "x-speakeasy-name-override": "create", - "summary": "Layout creation", - "description": "Create a layout", - "parameters": [], - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateLayoutResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_PropertyDescriptor", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.create();\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "LayoutsController_listLayouts", - "summary": "Filter layouts", - "description": "Returns a list of layouts that can be paginated using the `page` query parameter and filtered by the environment where it is executed from the organization the user belongs to.", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "description": "Number of page for pagination", - "schema": { "minimum": 0, "type": "number" } - }, - { - "name": "pageSize", - "required": false, - "in": "query", - "description": "Size of page for pagination", - "schema": { "minimum": 0, "type": "number" } - }, - { - "name": "sortBy", - "required": false, - "in": "query", - "description": "Sort field. Currently only supported `createdAt`", - "schema": { "type": "string" } - }, - { - "name": "orderBy", - "required": false, - "in": "query", - "description": "Direction of the sorting query param", - "schema": { "enum": ["ASC", "DESC"], "type": "string" } - } - ], - "responses": { - "200": { - "description": "The list of layouts that match the criteria of the query params are successfully returned." - }, - "400": { - "description": "Page size can not be larger than the page size limit." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_listLayouts", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.list({});\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/layouts/{layoutId}": { - "get": { - "operationId": "LayoutsController_getLayout", - "summary": "Get layout", - "description": "Get a layout by its ID", - "parameters": [ - { - "name": "layoutId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/GetLayoutResponseDto" - } - } - } - }, - "404": { - "description": "The layout with the layoutId provided does not exist in the database." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_getLayout", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "LayoutsController_deleteLayout", - "summary": "Delete layout", - "description": "Execute a soft delete of a layout given a certain ID.", - "parameters": [ - { - "name": "layoutId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { "description": "The layout has been deleted correctly" }, - "404": { - "description": "The layout with the layoutId provided does not exist in the database so it can not be deleted." - }, - "409": { - "description": "Either you are trying to delete a layout that is being used or a layout that is the default in the environment.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_deleteLayout", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.delete(\"\");\n\n \n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "LayoutsController_updateLayout", - "summary": "Update a layout", - "description": "Update the name, content and variables of a layout. Also change it to be default or no.", - "parameters": [ - { - "name": "layoutId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateLayoutRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateLayoutResponseDto" - } - } - } - }, - "400": { - "description": "The payload provided or the URL param are not right." - }, - "404": { - "description": "The layout with the layoutId provided does not exist in the database so it can not be updated." - }, - "409": { - "description": "One default layout is needed. If you are trying to turn a default layout as not default, you should turn a different layout as default first and automatically it will be done by the system.", - "content": { - "application/json": { - "schema": { "example": "One default layout is required" } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_updateLayout", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.update(\"\", {\n identifier: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/layouts/{layoutId}/default": { - "post": { - "operationId": "LayoutsController_setDefaultLayout", - "x-speakeasy-name-override": "setAsDefault", - "summary": "Set default layout", - "description": "Sets the default layout for the environment and updates to non default to the existing default layout (if any).", - "parameters": [ - { - "name": "layoutId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { - "description": "The selected layout has been set as the default for the environment." - }, - "404": { - "description": "The layout with the layoutId provided does not exist in the database so it can not be set as the default for the environment." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Layouts"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "LayoutsController_setDefaultLayout", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.setAsDefault(\"\");\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/messages": { - "get": { - "operationId": "MessagesController_getMessages", - "summary": "Get messages", - "description": "Returns a list of messages, could paginate using the `page` query parameter", - "parameters": [ - { - "name": "channel", - "required": false, - "in": "query", - "schema": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - } - }, - { - "name": "subscriberId", - "required": false, - "in": "query", - "schema": { "type": "string" } - }, - { - "name": "transactionId", - "required": false, - "in": "query", - "schema": { "type": "array", "items": { "type": "string" } } - }, - { - "name": "page", - "required": false, - "in": "query", - "schema": { "default": 0, "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "default": 10, "type": "number" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ActivitiesResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Messages"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "MessagesController_getMessages", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.messages.retrieve({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/messages/{messageId}": { - "delete": { - "operationId": "MessagesController_deleteMessage", - "summary": "Delete message", - "description": "Deletes a message entity from the Novu platform", - "parameters": [ - { - "name": "messageId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/DeleteMessageResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Messages"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "MessagesController_deleteMessage", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.messages.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/messages/transaction/{transactionId}": { - "delete": { - "operationId": "MessagesController_deleteMessagesByTransactionId", - "x-speakeasy-name-override": "deleteByTransactionId", - "summary": "Delete messages by transactionId", - "description": "Deletes messages entity from the Novu platform using TransactionId of message", - "parameters": [ - { - "name": "channel", - "required": false, - "in": "query", - "description": "The channel of the message to be deleted", - "schema": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - } - }, - { - "name": "transactionId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Messages"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "MessagesController_deleteMessagesByTransactionId", - "source": "import { Novu } from \"@novu/api\";\nimport { QueryParamChannel } from \"@novu/api/models/operations\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.messages.deleteByTransactionId(\"\", QueryParamChannel.Push);\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/topics": { - "post": { - "operationId": "TopicsController_createTopic", - "summary": "Topic creation", - "description": "Create a topic", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/CreateTopicRequestDto" } - } - } - }, - "responses": { - "201": { - "description": "Created", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateTopicResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_createTopic", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.create({\n key: \"\",\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "TopicsController_listTopics", - "summary": "Filter topics", - "description": "Returns a list of topics that can be paginated using the `page` query parameter and filtered by the topic key with the `key` query parameter", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "description": "Number of page for the pagination", - "schema": { "minimum": 0, "default": 0, "type": "number" } - }, - { - "name": "pageSize", - "required": false, - "in": "query", - "description": "Size of page for the pagination", - "schema": { "minimum": 0, "default": 10, "type": "number" } - }, - { - "name": "key", - "required": false, - "in": "query", - "description": "Topic key", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/FilterTopicsResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_listTopics", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.list({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/topics/{topicKey}/subscribers": { - "post": { - "operationId": "TopicsController_addSubscribers", - "x-speakeasy-name-override": "assign", - "x-speakeasy-group": "Topics.Subscribers", - "summary": "Subscribers addition", - "description": "Add subscribers to a topic by key", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/AddSubscribersRequestDto" - } - } - } - }, - "responses": { - "200": { "description": "" }, - "204": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_addSubscribers", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.subscribers.assign(\"\", {\n subscribers: [\n \"\",\n ],\n });\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/topics/{topicKey}/subscribers/{externalSubscriberId}": { - "get": { - "operationId": "TopicsController_getTopicSubscriber", - "x-speakeasy-group": "Topics.Subscribers", - "summary": "Check topic subscriber", - "description": "Check if a subscriber belongs to a certain topic", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - }, - { - "name": "externalSubscriberId", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/TopicSubscriberDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_getTopicSubscriber", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.subscribers.retrieve(\"\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/topics/{topicKey}/subscribers/removal": { - "post": { - "operationId": "TopicsController_removeSubscribers", - "x-speakeasy-group": "Topics.Subscribers", - "summary": "Subscribers removal", - "description": "Remove subscribers from a topic", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RemoveSubscribersRequestDto" - } - } - } - }, - "responses": { - "204": { "description": "" }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_removeSubscribers", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.subscribers.delete(\"\", {\n subscribers: [\n \"\",\n ],\n });\n\n \n}\n\nrun();" - } - ] - } - }, - "/v1/topics/{topicKey}": { - "delete": { - "operationId": "TopicsController_deleteTopic", - "summary": "Delete topic", - "description": "Delete a topic by its topic key if it has no subscribers", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { "description": "The topic has been deleted correctly" }, - "404": { - "description": "The topic with the key provided does not exist in the database so it can not be deleted." - }, - "409": { - "description": "The topic you are trying to delete has subscribers assigned to it. Delete the subscribers before deleting the topic.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_deleteTopic", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.delete(\"\");\n\n \n}\n\nrun();" - } - ] - }, - "get": { - "operationId": "TopicsController_getTopic", - "summary": "Get topic", - "description": "Get a topic by its topic key", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/GetTopicResponseDto" } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_getTopic", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "TopicsController_renameTopic", - "x-speakeasy-name-override": "rename", - "summary": "Rename a topic", - "description": "Rename a topic by providing a new name", - "parameters": [ - { - "name": "topicKey", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { "$ref": "#/components/schemas/RenameTopicRequestDto" } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/RenameTopicResponseDto" - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Topics"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TopicsController_renameTopic", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.rename(\"\", {\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/tenants": { - "get": { - "operationId": "TenantController_listTenants", - "x-speakeasy-pagination": { - "type": "offsetLimit", - "inputs": [ - { "name": "page", "in": "parameters", "type": "page" }, - { "name": "limit", "in": "parameters", "type": "limit" } - ], - "outputs": { "results": "$.data.resultArray" } - }, - "summary": "Get tenants", - "description": "Returns a list of tenants, could paginated using the `page` and `limit` query parameter", - "parameters": [ - { - "name": "page", - "required": false, - "in": "query", - "schema": { "type": "number" } - }, - { - "name": "limit", - "required": false, - "in": "query", - "schema": { "maximum": 100, "default": 10, "type": "number" } - } - ], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "allOf": [ - { "$ref": "#/components/schemas/PaginatedResponseDto" }, - { - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/GetTenantResponseDto" - } - } - } - } - ] - } - } - } - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Tenants"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TenantController_listTenants", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.list(7685.78, 10);\n\n for await (const page of result) {\n // handle page\n }\n}\n\nrun();" - } - ] - }, - "post": { - "operationId": "TenantController_createTenant", - "summary": "Create tenant", - "description": "Create tenant under the current environment", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateTenantRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateTenantResponseDto" - } - } - } - }, - "201": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateTenantResponseDto" - } - } - } - }, - "409": { - "description": "A tenant with the same identifier is already exist.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Tenants"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TenantController_createTenant", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.create({\n identifier: \"\",\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - } - }, - "/v1/tenants/{identifier}": { - "get": { - "operationId": "TenantController_getTenantById", - "summary": "Get tenant", - "description": "Get tenant by your internal id used to identify the tenant", - "parameters": [ - { - "name": "identifier", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/GetTenantResponseDto" - } - } - } - }, - "404": { - "description": "The tenant with the identifier provided does not exist in the database." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Tenants"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TenantController_getTenantById", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "patch": { - "operationId": "TenantController_updateTenant", - "summary": "Update tenant", - "description": "Update tenant by your internal id used to identify the tenant", - "parameters": [ - { - "name": "identifier", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateTenantRequestDto" - } - } - } - }, - "responses": { - "200": { - "description": "Ok", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/UpdateTenantResponseDto" - } - } - } - }, - "404": { - "description": "The tenant with the identifier provided does not exist in the database." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Tenants"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TenantController_updateTenant", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();" - } - ] - }, - "delete": { - "operationId": "TenantController_removeTenant", - "summary": "Delete tenant", - "description": "Deletes a tenant entity from the Novu platform", - "parameters": [ - { - "name": "identifier", - "required": true, - "in": "path", - "schema": { "type": "string" } - } - ], - "responses": { - "204": { "description": "The tenant has been deleted correctly" }, - "404": { - "description": "The tenant with the identifier provided does not exist in the database so it can not be deleted." - }, - "409": { - "description": "The request could not be completed due to a conflict with the current state of the target resource.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" - } - } - } - }, - "429": { - "description": "The client has sent too many requests in a given amount of time. ", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "API rate limit exceeded" - } - } - } - }, - "503": { - "description": "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay.", - "content": { - "application/json": { - "schema": { - "type": "string", - "example": "Please wait some time, then try again." - } - } - } - } - }, - "tags": ["Tenants"], - "security": [{ "api-key": [] }], - "x-codeSamples": [ - { - "lang": "typescript", - "label": "TenantController_removeTenant", - "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.tenants.delete(\"\");\n\n \n}\n\nrun();" - } - ] - } - } - }, - "info": { - "title": "Novu API", - "description": "Novu REST API. Please see https://docs.novu.co/api-reference for more details.", - "version": "1.0", - "contact": { - "name": "Novu Support", - "url": "https://discord.gg/novu", - "email": "support@novu.co" - }, - "termsOfService": "https://novu.co/terms", - "license": { "name": "MIT", "url": "https://opensource.org/license/mit" } - }, - "tags": [ - { - "name": "Events", - "description": "Events represent a change in state of a subscriber. They are used to trigger workflows, and enable you to send notifications to subscribers based on their actions.", - "externalDocs": { "url": "https://docs.novu.co/workflows" } - }, - { - "name": "Subscribers", - "description": "A subscriber in Novu represents someone who should receive a message. A subscriber’s profile information contains important attributes about the subscriber that will be used in messages (name, email). The subscriber object can contain other key-value pairs that can be used to further personalize your messages.", - "externalDocs": { "url": "https://docs.novu.co/subscribers/subscribers" } - }, - { - "name": "Topics", - "description": "Topics are a way to group subscribers together so that they can be notified of events at once. A topic is identified by a custom key. This can be helpful for things like sending out marketing emails or notifying users of new features. Topics can also be used to send notifications to the subscribers who have been grouped together based on their interests, location, activities and much more.", - "externalDocs": { "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.", - "externalDocs": { - "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" } - } - ], - "servers": [ - { "url": "https://api.novu.co" }, - { "url": "https://eu.api.novu.co" } - ], - "components": { - "securitySchemes": { - "api-key": { - "type": "apiKey", - "in": "header", - "name": "Authorization", - "description": "API key authentication. Allowed headers-- \"Authorization: ApiKey \"." - } - }, - "schemas": { - "DataWrapperDto": { - "type": "object", - "properties": { "data": { "type": "object" } }, - "required": ["data"] - }, - "OrganizationBrandingResponseDto": { - "type": "object", - "properties": { - "direction": { "enum": ["ltr", "trl"], "type": "string" }, - "logo": { "type": "string" }, - "color": { "type": "string" }, - "fontColor": { "type": "string" }, - "contentBackground": { "type": "string" }, - "fontFamily": { "type": "string" } - }, - "required": ["logo", "color", "fontColor", "contentBackground"] - }, - "IPartnerConfigurationResponseDto": { - "type": "object", - "properties": { - "projectIds": { "type": "array", "items": { "type": "string" } }, - "accessToken": { "type": "string" }, - "configurationId": { "type": "string" }, - "teamId": { "type": "string" }, - "partnerType": { - "type": "string", - "enum": ["vercel"], - "description": "Partner Type Enum" - } - }, - "required": ["accessToken", "configurationId", "partnerType"] - }, - "OrganizationResponseDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "logo": { "type": "string" }, - "branding": { - "$ref": "#/components/schemas/OrganizationBrandingResponseDto" - }, - "partnerConfigurations": { - "type": "array", - "items": { - "$ref": "#/components/schemas/IPartnerConfigurationResponseDto" - } - } - }, - "required": ["name", "branding"] - }, - "CreateOrganizationDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "logo": { "type": "string" }, - "jobTitle": { - "enum": [ - "engineer", - "engineering_manager", - "architect", - "product_manager", - "designer", - "cxo_founder", - "marketing_manager", - "other" - ], - "type": "string" - }, - "domain": { "type": "string" }, - "productUseCases": { "type": "object" } - }, - "required": ["name"] - }, - "MemberUserDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "firstName": { "type": "string" }, - "lastName": { "type": "string" }, - "email": { "type": "string" } - }, - "required": ["_id", "firstName", "lastName", "email"] - }, - "MemberInviteDTO": { - "type": "object", - "properties": { - "email": { "type": "string" }, - "token": { "type": "string" }, - "invitationDate": { "format": "date-time", "type": "string" }, - "answerDate": { "format": "date-time", "type": "string" }, - "_inviterId": { "type": "string" } - }, - "required": ["email", "token", "invitationDate", "_inviterId"] - }, - "MemberResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_userId": { "type": "string" }, - "user": { "$ref": "#/components/schemas/MemberUserDto" }, - "roles": { "enum": ["admin", "member"], "type": "string" }, - "invite": { "$ref": "#/components/schemas/MemberInviteDTO" }, - "memberStatus": { - "enum": ["new", "active", "invited"], - "type": "string" - }, - "_organizationId": { "type": "string" } - }, - "required": ["_id", "_userId", "_organizationId"] - }, - "UpdateBrandingDetailsDto": { - "type": "object", - "properties": { - "logo": { "type": "string" }, - "color": { "type": "string" }, - "fontColor": { "type": "string" }, - "contentBackground": { "type": "string" }, - "fontFamily": { "type": "string" } - }, - "required": ["logo", "color", "fontColor", "contentBackground"] - }, - "RenameOrganizationDto": { - "type": "object", - "properties": { "name": { "type": "string" } }, - "required": ["name"] - }, - "EnvironmentResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "_organizationId": { "type": "string" }, - "identifier": { "type": "string" }, - "apiKeys": { "type": "array", "items": { "type": "object" } }, - "_parentId": { "type": "string" } - }, - "required": ["name", "_organizationId", "identifier", "_parentId"] - }, - "ApiKey": { - "type": "object", - "properties": { - "key": { "type": "string" }, - "_userId": { "type": "string" } - }, - "required": ["key", "_userId"] - }, - "ExecutionDetailsResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_jobId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_notificationId": { "type": "string" }, - "_notificationTemplateId": { "type": "string" }, - "_subscriberId": { "type": "string" }, - "_messageId": { "type": "string" }, - "providerId": { "type": "string" }, - "transactionId": { "type": "string" }, - "channel": { - "type": "string", - "enum": [ - "in_app", - "email", - "sms", - "chat", - "push", - "digest", - "trigger", - "delay", - "custom" - ] - }, - "detail": { "type": "string" }, - "source": { - "type": "string", - "enum": ["Credentials", "Internal", "Payload", "Webhook"] - }, - "status": { - "type": "string", - "enum": [ - "Success", - "Warning", - "Failed", - "Pending", - "Queued", - "ReadConfirmation" - ] - }, - "isTest": { "type": "boolean" }, - "isRetry": { "type": "boolean" }, - "createdAt": { "type": "string" } - }, - "required": [ - "_organizationId", - "_jobId", - "_environmentId", - "_notificationId", - "_notificationTemplateId", - "_subscriberId", - "transactionId", - "channel", - "detail", - "source", - "status", - "isTest", - "isRetry" - ] - }, - "NotificationGroup": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_parentId": { "type": "string" } - }, - "required": ["name", "_environmentId", "_organizationId"] - }, - "PreferenceChannels": { - "type": "object", - "properties": { - "email": { "type": "boolean" }, - "sms": { "type": "boolean" }, - "in_app": { "type": "boolean" }, - "chat": { "type": "boolean" }, - "push": { "type": "boolean" } - } - }, - "DigestRegularMetadata": { - "type": "object", - "properties": { - "amount": { "type": "number" }, - "unit": { - "type": "string", - "enum": ["seconds", "minutes", "hours", "days", "weeks", "months"] - }, - "digestKey": { "type": "string" }, - "type": { "type": "string", "enum": ["regular", "backoff"] }, - "backoff": { "type": "boolean" }, - "backoffAmount": { "type": "number" }, - "backoffUnit": { - "type": "string", - "enum": ["seconds", "minutes", "hours", "days", "weeks", "months"] - }, - "updateMode": { "type": "boolean" } - }, - "required": ["type"] - }, - "TimedConfig": { - "type": "object", - "properties": { - "atTime": { "type": "string" }, - "weekDays": { - "type": "array", - "items": { - "type": "string", - "enum": [ - "monday", - "tuesday", - "wednesday", - "thursday", - "friday", - "saturday", - "sunday" - ] - } - }, - "monthDays": { "type": "array", "items": { "type": "string" } }, - "ordinal": { - "type": "string", - "enum": ["1", "2", "3", "4", "5", "last"] - }, - "ordinalValue": { - "type": "string", - "enum": [ - "day", - "weekday", - "weekend", - "sunday", - "monday", - "tuesday", - "wednesday", - "thursday", - "friday", - "saturday" - ] - }, - "monthlyType": { "type": "string", "enum": ["each", "on"] } - } - }, - "DigestTimedMetadata": { - "type": "object", - "properties": { - "amount": { "type": "number" }, - "unit": { - "type": "string", - "enum": ["seconds", "minutes", "hours", "days", "weeks", "months"] - }, - "digestKey": { "type": "string" }, - "type": { "type": "string", "enum": ["timed"] }, - "timed": { "$ref": "#/components/schemas/TimedConfig" } - }, - "required": ["type"] - }, - "DelayRegularMetadata": { - "type": "object", - "properties": { - "amount": { "type": "number" }, - "unit": { - "type": "string", - "enum": ["seconds", "minutes", "hours", "days", "weeks", "months"] - }, - "type": { "type": "string", "enum": ["regular"] } - }, - "required": ["type"] - }, - "DelayScheduledMetadata": { - "type": "object", - "properties": { - "type": { "type": "string", "enum": ["scheduled"] }, - "delayPath": { "type": "string" } - }, - "required": ["type", "delayPath"] - }, - "MessageTemplate": { "type": "object", "properties": {} }, - "FieldFilterPart": { - "type": "object", - "properties": { - "field": { "type": "string" }, - "value": { "type": "string" }, - "operator": { - "type": "string", - "enum": [ - "LARGER", - "SMALLER", - "LARGER_EQUAL", - "SMALLER_EQUAL", - "EQUAL", - "NOT_EQUAL", - "ALL_IN", - "ANY_IN", - "NOT_IN", - "BETWEEN", - "NOT_BETWEEN", - "LIKE", - "NOT_LIKE", - "IN" - ] - }, - "on": { "type": "string", "enum": ["subscriber", "payload"] } - }, - "required": ["field", "value", "operator", "on"] - }, - "StepFilter": { - "type": "object", - "properties": { - "isNegated": { "type": "boolean" }, - "type": { - "type": "string", - "enum": [ - "BOOLEAN", - "TEXT", - "DATE", - "NUMBER", - "STATEMENT", - "LIST", - "MULTI_LIST", - "GROUP" - ] - }, - "value": { "type": "string", "enum": ["AND", "OR"] }, - "children": { - "type": "array", - "items": { "$ref": "#/components/schemas/FieldFilterPart" } - } - }, - "required": ["isNegated", "type", "value", "children"] - }, - "NotificationStepVariant": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "uuid": { "type": "string" }, - "name": { "type": "string" }, - "_templateId": { "type": "string" }, - "active": { "type": "boolean" }, - "shouldStopOnFail": { "type": "boolean" }, - "template": { "$ref": "#/components/schemas/MessageTemplate" }, - "filters": { - "type": "array", - "items": { "$ref": "#/components/schemas/StepFilter" } - }, - "_parentId": { "type": "object" }, - "metadata": { - "oneOf": [ - { "$ref": "#/components/schemas/DigestRegularMetadata" }, - { "$ref": "#/components/schemas/DigestTimedMetadata" }, - { "$ref": "#/components/schemas/DelayRegularMetadata" }, - { "$ref": "#/components/schemas/DelayScheduledMetadata" } - ] - }, - "replyCallback": { "type": "object" } - } - }, - "NotificationStep": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "uuid": { "type": "string" }, - "name": { "type": "string" }, - "_templateId": { "type": "string" }, - "active": { "type": "boolean" }, - "shouldStopOnFail": { "type": "boolean" }, - "template": { "$ref": "#/components/schemas/MessageTemplate" }, - "filters": { - "type": "array", - "items": { "$ref": "#/components/schemas/StepFilter" } - }, - "_parentId": { "type": "object" }, - "metadata": { - "oneOf": [ - { "$ref": "#/components/schemas/DigestRegularMetadata" }, - { "$ref": "#/components/schemas/DigestTimedMetadata" }, - { "$ref": "#/components/schemas/DelayRegularMetadata" }, - { "$ref": "#/components/schemas/DelayScheduledMetadata" } - ] - }, - "replyCallback": { "type": "object" }, - "variants": { "$ref": "#/components/schemas/NotificationStepVariant" } - } - }, - "NotificationTriggerVariable": { - "type": "object", - "properties": { "name": { "type": "string" } }, - "required": ["name"] - }, - "NotificationTrigger": { - "type": "object", - "properties": { - "type": { "type": "string", "enum": ["event"] }, - "identifier": { "type": "string" }, - "variables": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationTriggerVariable" - } - }, - "subscriberVariables": { - "type": "array", - "items": { - "$ref": "#/components/schemas/NotificationTriggerVariable" - } - } - }, - "required": ["type", "identifier", "variables"] - }, - "WorkflowResponse": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "description": { "type": "string" }, - "active": { "type": "boolean" }, - "draft": { "type": "boolean" }, - "preferenceSettings": { - "$ref": "#/components/schemas/PreferenceChannels" - }, - "critical": { "type": "boolean" }, - "tags": { "type": "array", "items": { "type": "string" } }, - "steps": { - "type": "array", - "items": { "$ref": "#/components/schemas/NotificationStep" } - }, - "_organizationId": { "type": "string" }, - "_creatorId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "triggers": { - "type": "array", - "items": { "$ref": "#/components/schemas/NotificationTrigger" } - }, - "_notificationGroupId": { "type": "string" }, - "_parentId": { "type": "string" }, - "deleted": { "type": "boolean" }, - "deletedAt": { "type": "string" }, - "deletedBy": { "type": "string" }, - "notificationGroup": { - "$ref": "#/components/schemas/NotificationGroup" - }, - "data": { "type": "object" }, - "workflowIntegrationStatus": { "type": "object" } - }, - "required": [ - "name", - "description", - "active", - "draft", - "preferenceSettings", - "critical", - "tags", - "steps", - "_organizationId", - "_creatorId", - "_environmentId", - "triggers", - "_notificationGroupId", - "deleted", - "deletedAt", - "deletedBy" - ] - }, - "WorkflowsResponseDto": { - "type": "object", - "properties": { - "totalCount": { "type": "number" }, - "data": { - "type": "array", - "items": { "$ref": "#/components/schemas/WorkflowResponse" } - }, - "pageSize": { "type": "number" }, - "page": { "type": "number" } - }, - "required": ["totalCount", "data", "pageSize", "page"] - }, - "UpdateWorkflowRequestDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "tags": { "type": "array", "items": { "type": "string" } }, - "description": { "type": "string", "maxLength": 300 }, - "identifier": { "type": "string" }, - "steps": { - "type": "array", - "items": { "$ref": "#/components/schemas/NotificationStep" } - }, - "notificationGroupId": { "type": "string" }, - "critical": { "type": "boolean" }, - "preferenceSettings": { - "$ref": "#/components/schemas/PreferenceChannels" - }, - "data": { "type": "object" } - }, - "required": ["name", "notificationGroupId"] - }, - "DataBooleanDto": { - "type": "object", - "properties": { "data": { "type": "boolean" } }, - "required": ["data"] - }, - "VariablesResponseDto": { - "type": "object", - "properties": { - "translations": { "type": "object" }, - "system": { "type": "object" } - }, - "required": ["translations", "system"] - }, - "CreateWorkflowRequestDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "notificationGroupId": { "type": "string" }, - "notificationGroup": { "type": "object" }, - "tags": { "type": "array", "items": { "type": "string" } }, - "description": { "type": "string", "maxLength": 1000 }, - "steps": { - "type": "array", - "items": { "$ref": "#/components/schemas/NotificationStep" } - }, - "active": { "type": "boolean" }, - "draft": { "type": "boolean", "deprecated": true }, - "critical": { "type": "boolean" }, - "preferenceSettings": { - "$ref": "#/components/schemas/PreferenceChannels" - }, - "blueprintId": { "type": "string" }, - "data": { "type": "object" } - }, - "required": ["name", "notificationGroupId", "steps"] - }, - "ChangeWorkflowStatusRequestDto": { - "type": "object", - "properties": { "active": { "type": "boolean" } }, - "required": ["active"] - }, - "TriggerEventResponseDto": { - "type": "object", - "properties": { - "acknowledged": { - "type": "boolean", - "description": "If trigger was acknowledged or not" - }, - "status": { - "enum": [ - "error", - "trigger_not_active", - "no_workflow_active_steps_defined", - "no_workflow_steps_defined", - "processed", - "subscriber_id_missing", - "no_tenant_found" - ], - "type": "string", - "description": "Status for trigger" - }, - "error": { - "description": "In case of an error, this field will contain the error message", - "type": "array", - "items": { "type": "string" } - }, - "transactionId": { - "type": "string", - "description": "Transaction id for trigger" - } - }, - "required": ["acknowledged", "status"] - }, - "TopicPayloadDto": { - "type": "object", - "properties": { - "topicKey": { "type": "string", "example": "topic_key" }, - "type": { - "enum": ["Subscriber", "Topic"], - "type": "string", - "example": "Topic" - } - }, - "required": ["topicKey", "type"] - }, - "TenantPayloadDto": { - "type": "object", - "properties": { - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" } - } - }, - "ChannelCredentialsDto": { - "type": "object", - "properties": { - "webhookUrl": { "type": "string" }, - "deviceTokens": { "type": "array", "items": { "type": "string" } } - } - }, - "SubscriberChannelDto": { - "type": "object", - "properties": { - "integrationIdentifier": { "type": "string" }, - "providerId": { "type": "object" }, - "credentials": { - "$ref": "#/components/schemas/ChannelCredentialsDto" - } - }, - "required": ["providerId", "credentials"] - }, - "SubscriberPayloadDto": { - "type": "object", - "properties": { - "subscriberId": { - "type": "string", - "description": "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" - }, - "email": { "type": "string" }, - "firstName": { "type": "string" }, - "lastName": { "type": "string" }, - "phone": { "type": "string" }, - "avatar": { - "type": "string", - "description": "An http url to the profile image of your subscriber" - }, - "locale": { "type": "string" }, - "data": { "type": "object" }, - "channels": { - "type": "array", - "items": { "$ref": "#/components/schemas/SubscriberChannelDto" } - } - }, - "required": ["subscriberId"] - }, - "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" - }, - "payload": { - "type": "object", - "description": "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. \n This data will also be available when fetching the notifications feed from the API to display certain parts of the UI.", - "example": { "comment_id": "string", "post": { "text": "string" } } - }, - "overrides": { - "type": "object", - "description": "This could be used to override provider specific configurations", - "example": { "fcm": { "data": { "key": "value" } } } - }, - "to": { - "type": "array", - "description": "The recipients list of people who will receive the notification.", - "items": { - "oneOf": [ - { "$ref": "#/components/schemas/SubscriberPayloadDto" }, - { - "type": "string", - "description": "Unique identifier of a subscriber in your systems", - "example": "SUBSCRIBER_ID" - }, - { "$ref": "#/components/schemas/TopicPayloadDto" } - ] - } - }, - "transactionId": { - "type": "string", - "description": "A unique identifier for this transaction, we will generated a UUID if not provided." - }, - "actor": { - "description": "It is used to display the Avatar of the provided actor's subscriber id or actor object.\n If a new actor object is provided, we will create a new subscriber in our system\n ", - "oneOf": [ - { - "type": "string", - "description": "Unique identifier of a subscriber in your systems" - }, - { "$ref": "#/components/schemas/SubscriberPayloadDto" } - ] - }, - "tenant": { - "description": "It is used to specify a tenant context during trigger event.\n Existing tenants will be updated with the provided details.\n ", - "oneOf": [ - { - "type": "string", - "description": "Unique identifier of a tenant in your system" - }, - { "$ref": "#/components/schemas/TenantPayloadDto" } - ] - } - }, - "required": ["name", "to"] - }, - "BulkTriggerEventDto": { - "type": "object", - "properties": { - "events": { - "type": "array", - "items": { "$ref": "#/components/schemas/TriggerEventRequestDto" } - } - }, - "required": ["events"] - }, - "TriggerEventToAllRequestDto": { - "type": "object", - "properties": { - "name": { - "type": "string", - "description": "The trigger identifier associated for the template you wish to send. This identifier can be found on the template page." - }, - "payload": { - "type": "object", - "description": "The payload object is used to pass additional custom information that could be used to render the template, 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.", - "example": { "comment_id": "string", "post": { "text": "string" } } - }, - "overrides": { - "type": "object", - "description": "This could be used to override provider specific configurations", - "example": { "fcm": { "data": { "key": "value" } } } - }, - "transactionId": { - "type": "string", - "description": "A unique identifier for this transaction, we will generated a UUID if not provided." - }, - "actor": { - "description": "It is used to display the Avatar of the provided actor's subscriber id or actor object.\n If a new actor object is provided, we will create a new subscriber in our system\n ", - "oneOf": [ - { - "type": "string", - "description": "Unique identifier of a subscriber in your systems" - }, - { "$ref": "#/components/schemas/SubscriberPayloadDto" } - ] - }, - "tenant": { - "description": "It is used to specify a tenant context during trigger event.\n If a new tenant object is provided, we will create a new tenant.\n ", - "oneOf": [ - { - "type": "string", - "description": "Unique identifier of a tenant in your system" - }, - { "$ref": "#/components/schemas/TenantPayloadDto" } - ] - } - }, - "required": ["name", "payload"] - }, - "ActivityNotificationSubscriberResponseDto": { - "type": "object", - "properties": { - "firstName": { "type": "string" }, - "_id": { "type": "string" }, - "lastName": { "type": "string" }, - "email": { "type": "string" }, - "phone": { "type": "string" } - }, - "required": ["_id"] - }, - "ActivityNotificationTemplateResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "triggers": { - "type": "array", - "items": { "$ref": "#/components/schemas/NotificationTrigger" } - } - }, - "required": ["name", "triggers"] - }, - "ActivityNotificationExecutionDetailResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_jobId": { "type": "string" }, - "status": { - "enum": [ - "Success", - "Warning", - "Failed", - "Pending", - "Queued", - "ReadConfirmation" - ], - "type": "string" - }, - "detail": { "type": "string" }, - "isRetry": { "type": "boolean" }, - "isTest": { "type": "boolean" }, - "providerId": { "type": "object" }, - "raw": { "type": "string" }, - "source": { - "enum": ["Credentials", "Internal", "Payload", "Webhook"], - "type": "string" - } - }, - "required": [ - "_id", - "_jobId", - "status", - "detail", - "isRetry", - "isTest", - "providerId", - "source" - ] - }, - "MessageTemplateDto": { "type": "object", "properties": {} }, - "ActivityNotificationStepResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "active": { "type": "boolean" }, - "filters": { "$ref": "#/components/schemas/StepFilter" }, - "template": { "$ref": "#/components/schemas/MessageTemplateDto" } - }, - "required": ["_id", "active", "filters"] - }, - "ActivityNotificationJobResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "type": { "type": "string" }, - "digest": { "type": "object" }, - "executionDetails": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ActivityNotificationExecutionDetailResponseDto" - } - }, - "step": { - "$ref": "#/components/schemas/ActivityNotificationStepResponseDto" - }, - "payload": { "type": "object" }, - "providerId": { "type": "object" }, - "status": { "type": "string" } - }, - "required": [ - "_id", - "type", - "executionDetails", - "step", - "providerId", - "status" - ] - }, - "ActivityNotificationResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "transactionId": { "type": "string" }, - "createdAt": { "type": "string" }, - "channels": { - "type": "string", - "items": { - "type": "string", - "enum": [ - "in_app", - "email", - "sms", - "chat", - "push", - "digest", - "trigger", - "delay", - "custom" - ] - }, - "enum": [ - "in_app", - "email", - "sms", - "chat", - "push", - "digest", - "trigger", - "delay", - "custom" - ] - }, - "subscriber": { - "$ref": "#/components/schemas/ActivityNotificationSubscriberResponseDto" - }, - "template": { - "$ref": "#/components/schemas/ActivityNotificationTemplateResponseDto" - }, - "jobs": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ActivityNotificationJobResponseDto" - } - } - }, - "required": ["_environmentId", "_organizationId", "transactionId"] - }, - "ActivitiesResponseDto": { - "type": "object", - "properties": { - "hasMore": { "type": "boolean" }, - "data": { - "type": "array", - "items": { - "$ref": "#/components/schemas/ActivityNotificationResponseDto" - } - }, - "pageSize": { "type": "number" }, - "page": { "type": "number" } - }, - "required": ["hasMore", "data", "pageSize", "page"] - }, - "ActivityStatsResponseDto": { - "type": "object", - "properties": { - "weeklySent": { "type": "number" }, - "monthlySent": { "type": "number" } - }, - "required": ["weeklySent", "monthlySent"] - }, - "ActivityGraphStatesResponse": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "count": { "type": "number" }, - "templates": { "type": "array", "items": { "type": "string" } }, - "channels": { - "type": "array", - "items": { - "type": "string", - "enum": ["in_app", "email", "sms", "chat", "push"] - } - } - }, - "required": ["_id", "count", "templates", "channels"] - }, - "NotificationGroupResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_parentId": { "type": "string" } - }, - "required": ["name", "_environmentId", "_organizationId"] - }, - "CreateNotificationGroupRequestDto": { - "type": "object", - "properties": { "name": { "type": "string" } }, - "required": ["name"] - }, - "DeleteNotificationGroupResponseDto": { - "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"] - }, - "CredentialsDto": { - "type": "object", - "properties": { - "apiKey": { "type": "string" }, - "user": { "type": "string" }, - "secretKey": { "type": "string" }, - "domain": { "type": "string" }, - "password": { "type": "string" }, - "host": { "type": "string" }, - "port": { "type": "string" }, - "secure": { "type": "boolean" }, - "region": { "type": "string" }, - "accountSid": { "type": "string" }, - "messageProfileId": { "type": "string" }, - "token": { "type": "string" }, - "from": { "type": "string" }, - "senderName": { "type": "string" }, - "projectName": { "type": "string" }, - "applicationId": { "type": "string" }, - "clientId": { "type": "string" }, - "requireTls": { "type": "boolean" }, - "ignoreTls": { "type": "boolean" }, - "tlsOptions": { "type": "object" }, - "baseUrl": { "type": "string" }, - "webhookUrl": { "type": "string" }, - "redirectUrl": { "type": "string" }, - "hmac": { "type": "boolean" }, - "serviceAccount": { "type": "string" }, - "ipPoolName": { "type": "string" }, - "apiKeyRequestHeader": { "type": "string" }, - "secretKeyRequestHeader": { "type": "string" }, - "idPath": { "type": "string" }, - "datePath": { "type": "string" }, - "apiToken": { "type": "string" }, - "authenticateByToken": { "type": "boolean" }, - "authenticationTokenKey": { "type": "string" }, - "instanceId": { "type": "string" }, - "alertUid": { "type": "string" }, - "title": { "type": "string" }, - "imageUrl": { "type": "string" }, - "state": { "type": "string" }, - "externalLink": { "type": "string" }, - "channelId": { "type": "string" }, - "phoneNumberIdentification": { "type": "string" } - } - }, - "IntegrationResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "providerId": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "credentials": { "$ref": "#/components/schemas/CredentialsDto" }, - "active": { "type": "boolean" }, - "deleted": { "type": "boolean" }, - "deletedAt": { "type": "string" }, - "deletedBy": { "type": "string" }, - "primary": { "type": "boolean" }, - "conditions": { - "type": "array", - "items": { "$ref": "#/components/schemas/StepFilter" } - } - }, - "required": [ - "_environmentId", - "_organizationId", - "name", - "identifier", - "providerId", - "channel", - "credentials", - "active", - "deleted", - "deletedAt", - "deletedBy", - "primary" - ] - }, - "CreateIntegrationRequestDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "_environmentId": { "type": "string" }, - "providerId": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "credentials": { "$ref": "#/components/schemas/CredentialsDto" }, - "active": { - "type": "boolean", - "description": "If the integration is active the validation on the credentials field will run" - }, - "check": { "type": "boolean" }, - "conditions": { - "type": "array", - "items": { "$ref": "#/components/schemas/StepFilter" } - } - }, - "required": ["providerId", "channel"] - }, - "UpdateIntegrationRequestDto": { - "type": "object", - "properties": { - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "_environmentId": { "type": "string" }, - "active": { - "type": "boolean", - "description": "If the integration is active the validation on the credentials field will run" - }, - "credentials": { "$ref": "#/components/schemas/CredentialsDto" }, - "check": { "type": "boolean" }, - "conditions": { - "type": "array", - "items": { "$ref": "#/components/schemas/StepFilter" } - } - } - }, - "ChangeResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_creatorId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_entityId": { "type": "string" }, - "enabled": { "type": "boolean" }, - "type": { - "enum": [ - "Feed", - "MessageTemplate", - "Layout", - "DefaultLayout", - "NotificationTemplate", - "NotificationGroup", - "TranslationGroup", - "Translation" - ], - "type": "string" - }, - "change": { "type": "object" }, - "createdAt": { "type": "string" }, - "_parentId": { "type": "string" } - }, - "required": [ - "_creatorId", - "_environmentId", - "_organizationId", - "_entityId", - "enabled", - "type", - "change", - "createdAt" - ] - }, - "ChangesResponseDto": { - "type": "object", - "properties": { - "totalCount": { "type": "number" }, - "data": { - "type": "array", - "items": { "$ref": "#/components/schemas/ChangeResponseDto" } - }, - "pageSize": { "type": "number" }, - "page": { "type": "number" } - }, - "required": ["totalCount", "data", "pageSize", "page"] - }, - "DataNumberDto": { - "type": "object", - "properties": { "data": { "type": "number" } }, - "required": ["data"] - }, - "BulkApplyChangeDto": { - "type": "object", - "properties": { - "changeIds": { "type": "array", "items": { "type": "string" } } - }, - "required": ["changeIds"] - }, - "PaginatedResponseDto": { - "type": "object", - "properties": { - "page": { - "type": "number", - "description": "The current page of the paginated response" - }, - "hasMore": { - "type": "boolean", - "description": "Does the list have more items to fetch" - }, - "pageSize": { - "type": "number", - "description": "Number of items on each page" - }, - "data": { - "description": "The list of items matching the query", - "type": "array", - "items": { "type": "object" } - } - }, - "required": ["page", "hasMore", "pageSize", "data"] - }, - "ChannelCredentials": { - "type": "object", - "properties": { - "webhookUrl": { - "type": "string", - "description": "Webhook url used by chat app integrations. The webhook should be obtained from the chat app provider." - }, - "channel": { - "type": "string", - "description": "Channel specification for Mattermost chat notifications" - }, - "deviceTokens": { - "description": "Contains an array of the subscriber device tokens for a given provider. Used on Push integrations", - "type": "array", - "items": { "type": "string" } - }, - "alertUid": { - "type": "string", - "description": "alert_uid for grafana on-call webhook payload" - }, - "title": { - "type": "string", - "description": "title to be used with grafana on call webhook" - }, - "imageUrl": { - "type": "string", - "description": "image_url property fo grafana on call webhook" - }, - "state": { - "type": "string", - "description": "state property fo grafana on call webhook" - }, - "externalUrl": { - "type": "string", - "description": "link_to_upstream_details property fo grafana on call webhook" - } - }, - "required": ["webhookUrl"] - }, - "ChannelSettings": { - "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" - }, - "integrationIdentifier": { - "type": "string", - "description": "The integration identifier" - }, - "credentials": { - "description": "Credentials payload for the specified provider", - "allOf": [{ "$ref": "#/components/schemas/ChannelCredentials" }] - }, - "_integrationId": { - "type": "string", - "description": "Id of the integration that is used for this channel" - } - }, - "required": ["providerId", "credentials", "_integrationId"] - }, - "SubscriberResponseDto": { - "type": "object", - "properties": { - "_id": { - "type": "string", - "description": "The internal id novu generated for your subscriber, this is not the subscriberId matching your query. See `subscriberId` for that" - }, - "firstName": { "type": "string" }, - "lastName": { "type": "string" }, - "email": { "type": "string" }, - "phone": { "type": "string" }, - "avatar": { "type": "string" }, - "locale": { "type": "string" }, - "subscriberId": { - "type": "string", - "description": "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" - }, - "channels": { - "description": "Channels settings for subscriber", - "type": "array", - "items": { "$ref": "#/components/schemas/ChannelSettings" } - }, - "isOnline": { "type": "boolean" }, - "lastOnlineAt": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "deleted": { "type": "boolean" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" }, - "__v": { "type": "number" } - }, - "required": [ - "subscriberId", - "_organizationId", - "_environmentId", - "deleted", - "createdAt", - "updatedAt" - ] - }, - "CreateSubscriberRequestDto": { - "type": "object", - "properties": { - "subscriberId": { - "type": "string", - "description": "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" - }, - "email": { "type": "string" }, - "firstName": { "type": "string" }, - "lastName": { "type": "string" }, - "phone": { "type": "string" }, - "avatar": { - "type": "string", - "description": "An http url to the profile image of your subscriber" - }, - "locale": { "type": "string" }, - "data": { "type": "object" }, - "channels": { - "type": "array", - "items": { "$ref": "#/components/schemas/SubscriberChannelDto" } - } - }, - "required": ["subscriberId"] - }, - "BulkSubscriberCreateDto": { - "type": "object", - "properties": { - "subscribers": { - "type": "array", - "items": { - "$ref": "#/components/schemas/CreateSubscriberRequestDto" - } - } - }, - "required": ["subscribers"] - }, - "UpdateSubscriberRequestDto": { - "type": "object", - "properties": { - "email": { "type": "string" }, - "firstName": { "type": "string" }, - "lastName": { "type": "string" }, - "phone": { "type": "string" }, - "avatar": { "type": "string" }, - "locale": { "type": "string" }, - "data": { "type": "object" } - } - }, - "UpdateSubscriberChannelRequestDto": { - "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" - }, - "integrationIdentifier": { - "type": "string", - "description": "The integration identifier" - }, - "credentials": { - "description": "Credentials payload for the specified provider", - "allOf": [{ "$ref": "#/components/schemas/ChannelCredentials" }] - } - }, - "required": ["providerId", "credentials"] - }, - "UpdateSubscriberOnlineFlagRequestDto": { - "type": "object", - "properties": { "isOnline": { "type": "boolean" } }, - "required": ["isOnline"] - }, - "DeleteSubscriberResponseDto": { - "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"] - }, - "TemplateResponse": { - "type": "object", - "properties": { - "_id": { - "type": "string", - "description": "Unique identifier of the workflow" - }, - "name": { "type": "string", "description": "Name of the workflow" }, - "critical": { - "type": "boolean", - "description": "Critical templates will always be delivered to the end user and should be hidden from the subscriber preferences screen" - }, - "triggers": { - "description": "Triggers are the events that will trigger the workflow.", - "type": "array", - "items": { "type": "string" } - } - }, - "required": ["_id", "name", "critical", "triggers"] - }, - "Preference": { - "type": "object", - "properties": { - "enabled": { - "type": "boolean", - "description": "Sets if the workflow is fully enabled for all channels or not for the subscriber." - }, - "channels": { - "description": "Subscriber preferences for the different channels regarding this workflow", - "allOf": [{ "$ref": "#/components/schemas/PreferenceChannels" }] - } - }, - "required": ["enabled", "channels"] - }, - "UpdateSubscriberPreferenceResponseDto": { - "type": "object", - "properties": { - "template": { - "description": "The workflow information and if it is critical or not", - "allOf": [{ "$ref": "#/components/schemas/TemplateResponse" }] - }, - "preference": { - "description": "The preferences of the subscriber regarding the related workflow", - "allOf": [{ "$ref": "#/components/schemas/Preference" }] - } - }, - "required": ["template", "preference"] - }, - "GetSubscriberPreferencesResponseDto": { - "type": "object", - "properties": { - "template": { - "description": "The workflow information and if it is critical or not", - "allOf": [{ "$ref": "#/components/schemas/TemplateResponse" }] - }, - "preference": { - "description": "The preferences of the subscriber regarding the related workflow", - "allOf": [{ "$ref": "#/components/schemas/Preference" }] - } - }, - "required": ["preference"] - }, - "ChannelPreference": { - "type": "object", - "properties": { - "type": { - "type": "string", - "enum": ["in_app", "email", "sms", "chat", "push"], - "description": "The type of channel that is enabled or not" - }, - "enabled": { - "type": "boolean", - "description": "If channel is enabled or not" - } - }, - "required": ["type", "enabled"] - }, - "UpdateSubscriberPreferenceRequestDto": { - "type": "object", - "properties": { - "channel": { - "description": "The subscriber preferences for every ChannelTypeEnum for the workflow assigned.", - "allOf": [{ "$ref": "#/components/schemas/ChannelPreference" }] - }, - "enabled": { - "type": "boolean", - "description": "Sets if the workflow is fully enabled for all channels or not for the subscriber." - } - } - }, - "UpdateSubscriberGlobalPreferencesRequestDto": { - "type": "object", - "properties": { - "enabled": { - "type": "boolean", - "description": "Enable or disable the subscriber global preferences." - }, - "preferences": { - "description": "The subscriber global preferences for every ChannelTypeEnum.", - "type": "array", - "items": { "$ref": "#/components/schemas/ChannelPreference" } - } - } - }, - "EmailBlockStyles": { - "type": "object", - "properties": { - "textAlign": { "enum": ["left", "right", "center"], "type": "string" } - } - }, - "EmailBlock": { - "type": "object", - "properties": { - "type": { "enum": ["text", "button"], "type": "string" }, - "content": { "type": "string" }, - "url": { "type": "string" }, - "styles": { "$ref": "#/components/schemas/EmailBlockStyles" } - }, - "required": ["type", "content"] - }, - "MessageCTAData": { - "type": "object", - "properties": { "url": { "type": "string" } } - }, - "MessageButton": { - "type": "object", - "properties": { - "type": { - "enum": ["primary", "secondary", "clicked"], - "type": "string" - }, - "content": { "type": "string" }, - "resultContent": { "type": "string" } - }, - "required": ["type", "content"] - }, - "MessageActionResult": { - "type": "object", - "properties": { - "payload": { "type": "object" }, - "type": { - "enum": ["primary", "secondary", "clicked"], - "type": "string" - } - } - }, - "MessageAction": { - "type": "object", - "properties": { - "status": { "enum": ["pending", "done"], "type": "string" }, - "buttons": { - "type": "array", - "items": { "$ref": "#/components/schemas/MessageButton" } - }, - "result": { "$ref": "#/components/schemas/MessageActionResult" } - } - }, - "MessageCTA": { - "type": "object", - "properties": { - "type": { "type": "string", "enum": ["redirect"] }, - "data": { "$ref": "#/components/schemas/MessageCTAData" }, - "action": { "$ref": "#/components/schemas/MessageAction" } - }, - "required": ["data"] - }, - "Actor": { - "type": "object", - "properties": { - "data": { "type": "string", "nullable": true }, - "type": { - "enum": ["none", "user", "system_icon", "system_custom"], - "type": "string" - } - }, - "required": ["data", "type"] - }, - "NotificationDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_templateId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_messageTemplateId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_notificationId": { "type": "string" }, - "_subscriberId": { "type": "string" }, - "_feedId": { "type": "string" }, - "_jobId": { "type": "string" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" }, - "expireAt": { "type": "string" }, - "actor": { "$ref": "#/components/schemas/Actor" }, - "subscriber": { - "$ref": "#/components/schemas/SubscriberResponseDto" - }, - "transactionId": { "type": "string" }, - "templateIdentifier": { "type": "string" }, - "providerId": { "type": "string" }, - "content": { "type": "string" }, - "subject": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "read": { "type": "boolean" }, - "seen": { "type": "boolean" }, - "deleted": { "type": "boolean" }, - "deviceTokens": { "type": "array", "items": { "type": "string" } }, - "cta": { "$ref": "#/components/schemas/MessageCTA" }, - "status": { "type": "string", "enum": ["sent", "error", "warning"] }, - "payload": { - "type": "object", - "description": "The payload that was used to send the notification trigger" - }, - "overrides": { - "type": "object", - "description": "Provider specific overrides used when triggering the notification" - } - }, - "required": [ - "_templateId", - "_environmentId", - "_messageTemplateId", - "_organizationId", - "_notificationId", - "_subscriberId", - "_feedId", - "_jobId", - "transactionId", - "content", - "channel", - "read", - "seen", - "deleted", - "cta", - "status", - "payload", - "overrides" - ] - }, - "FeedResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_organizationId": { "type": "string" } - }, - "required": ["name", "identifier", "_environmentId", "_organizationId"] - }, - "UnseenCountResponse": { - "type": "object", - "properties": { "count": { "type": "number" } }, - "required": ["count"] - }, - "MessageMarkAsRequestDto": { - "type": "object", - "properties": { - "messageId": { - "oneOf": [ - { "type": "string" }, - { "type": "array", "items": { "type": "string" } } - ] - }, - "markAs": { - "enum": ["read", "seen", "unread", "unseen"], - "type": "string" - } - }, - "required": ["messageId", "markAs"] - }, - "MessageEntity": { "type": "object", "properties": {} }, - "MarkAllMessageAsRequestDto": { - "type": "object", - "properties": { - "feedIdentifier": { - "oneOf": [ - { "type": "string" }, - { "type": "array", "items": { "type": "string" } } - ], - "description": "Optional feed identifier or array of feed identifiers" - }, - "markAs": { - "enum": ["read", "seen", "unread", "unseen"], - "type": "string", - "description": "Mark all subscriber messages as read, unread, seen or unseen" - } - }, - "required": ["markAs"] - }, - "MessageResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_templateId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_messageTemplateId": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_notificationId": { "type": "string" }, - "_subscriberId": { "type": "string" }, - "subscriber": { - "$ref": "#/components/schemas/SubscriberResponseDto" - }, - "template": { "$ref": "#/components/schemas/WorkflowResponse" }, - "templateIdentifier": { "type": "string" }, - "createdAt": { "type": "string" }, - "lastSeenDate": { "type": "string" }, - "lastReadDate": { "type": "string" }, - "content": { - "oneOf": [ - { "$ref": "#/components/schemas/EmailBlock" }, - { "type": "string" } - ] - }, - "transactionId": { "type": "string" }, - "subject": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "read": { "type": "boolean" }, - "seen": { "type": "boolean" }, - "email": { "type": "string" }, - "phone": { "type": "string" }, - "directWebhookUrl": { "type": "string" }, - "providerId": { "type": "string" }, - "deviceTokens": { "type": "array", "items": { "type": "string" } }, - "title": { "type": "string" }, - "cta": { "$ref": "#/components/schemas/MessageCTA" }, - "_feedId": { "type": "string", "nullable": true }, - "status": { "type": "string", "enum": ["sent", "error", "warning"] }, - "errorId": { "type": "string" }, - "errorText": { "type": "string" }, - "payload": { - "type": "object", - "description": "The payload that was used to send the notification trigger" - }, - "overrides": { - "type": "object", - "description": "Provider specific overrides used when triggering the notification" - } - }, - "required": [ - "_templateId", - "_environmentId", - "_messageTemplateId", - "_organizationId", - "_notificationId", - "_subscriberId", - "createdAt", - "content", - "transactionId", - "channel", - "read", - "seen", - "cta", - "status", - "errorId", - "errorText", - "payload", - "overrides" - ] - }, - "MarkMessageActionAsSeenDto": { - "type": "object", - "properties": { - "status": { - "enum": ["pending", "done"], - "type": "string", - "description": "Message action status" - }, - "payload": { - "type": "object", - "description": "Message action payload" - } - }, - "required": ["status"] - }, - "CreateFeedRequestDto": { - "type": "object", - "properties": { "name": { "type": "string" } }, - "required": ["name"] - }, - "CreateLayoutResponseDto": { - "type": "object", - "properties": { "_id": { "type": "string" } }, - "required": ["_id"] - }, - "GetLayoutResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_creatorId": { "type": "string" }, - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "description": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "content": { "type": "string" }, - "contentType": { "type": "string" }, - "variables": { "type": "array", "items": { "type": "object" } }, - "isDefault": { "type": "boolean" }, - "isDeleted": { "type": "boolean" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" }, - "_parentId": { "type": "string" } - }, - "required": [ - "_organizationId", - "_environmentId", - "_creatorId", - "name", - "identifier", - "channel", - "content", - "contentType", - "isDefault", - "isDeleted" - ] - }, - "UpdateLayoutResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_creatorId": { "type": "string" }, - "name": { "type": "string" }, - "identifier": { "type": "string" }, - "description": { "type": "string" }, - "channel": { - "enum": ["in_app", "email", "sms", "chat", "push"], - "type": "string" - }, - "content": { "type": "string" }, - "contentType": { "type": "string" }, - "variables": { "type": "array", "items": { "type": "object" } }, - "isDefault": { "type": "boolean" }, - "isDeleted": { "type": "boolean" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" }, - "_parentId": { "type": "string" } - }, - "required": [ - "_organizationId", - "_environmentId", - "_creatorId", - "name", - "identifier", - "channel", - "content", - "contentType", - "isDefault", - "isDeleted" - ] - }, - "UpdateLayoutRequestDto": { - "type": "object", - "properties": { - "name": { - "type": "string", - "description": "User defined custom name and provided by the user that will name the Layout updated." - }, - "identifier": { - "type": "string", - "description": "User defined custom key that will be a unique identifier for the Layout updated." - }, - "description": { - "type": "string", - "description": "User defined description of the layout" - }, - "content": { - "type": "string", - "description": "User defined content for the layout." - }, - "variables": { - "description": "User defined variables to render in the layout placeholders.", - "type": "array", - "items": { "type": "object" } - }, - "isDefault": { - "type": "boolean", - "description": "Variable that defines if the layout is chosen as default when creating a layout." - } - }, - "required": ["identifier"] - }, - "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": {} }, - "CreateTopicRequestDto": { - "type": "object", - "properties": { - "key": { - "type": "string", - "description": "User defined custom key and provided by the user that will be an unique identifier for the Topic created." - }, - "name": { - "type": "string", - "description": "User defined custom name and provided by the user that will name the Topic created." - } - }, - "required": ["key", "name"] - }, - "AddSubscribersRequestDto": { - "type": "object", - "properties": { - "subscribers": { - "description": "List of subscriber identifiers that will be associated to the topic", - "type": "array", - "items": { "type": "string" } - } - }, - "required": ["subscribers"] - }, - "TopicSubscriberDto": { - "type": "object", - "properties": { - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "_subscriberId": { "type": "string" }, - "_topicId": { "type": "string" }, - "topicKey": { "type": "string" }, - "externalSubscriberId": { "type": "string" } - }, - "required": [ - "_organizationId", - "_environmentId", - "_subscriberId", - "_topicId", - "topicKey", - "externalSubscriberId" - ] - }, - "RemoveSubscribersRequestDto": { - "type": "object", - "properties": { - "subscribers": { - "description": "List of subscriber identifiers that will be removed to the topic", - "type": "array", - "items": { "type": "string" } - } - }, - "required": ["subscribers"] - }, - "TopicDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "key": { "type": "string" }, - "name": { "type": "string" }, - "subscribers": { "type": "array", "items": { "type": "string" } } - }, - "required": [ - "_organizationId", - "_environmentId", - "key", - "name", - "subscribers" - ] - }, - "FilterTopicsResponseDto": { - "type": "object", - "properties": { - "data": { - "type": "array", - "items": { "$ref": "#/components/schemas/TopicDto" } - }, - "page": { "type": "number" }, - "pageSize": { "type": "number" }, - "totalCount": { "type": "number" } - }, - "required": ["data", "page", "pageSize", "totalCount"] - }, - "GetTopicResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "key": { "type": "string" }, - "name": { "type": "string" }, - "subscribers": { "type": "array", "items": { "type": "string" } } - }, - "required": [ - "_organizationId", - "_environmentId", - "key", - "name", - "subscribers" - ] - }, - "RenameTopicResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "_organizationId": { "type": "string" }, - "_environmentId": { "type": "string" }, - "key": { "type": "string" }, - "name": { "type": "string" }, - "subscribers": { "type": "array", "items": { "type": "string" } } - }, - "required": [ - "_organizationId", - "_environmentId", - "key", - "name", - "subscribers" - ] - }, - "RenameTopicRequestDto": { - "type": "object", - "properties": { - "name": { - "type": "string", - "description": "User defined custom name and provided by the user to rename the topic." - } - }, - "required": ["name"] - }, - "GetTenantResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" }, - "_environmentId": { "type": "string" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" } - }, - "required": [ - "_id", - "identifier", - "_environmentId", - "createdAt", - "updatedAt" - ] - }, - "CreateTenantResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" }, - "_environmentId": { "type": "string" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" } - }, - "required": [ - "_id", - "identifier", - "_environmentId", - "createdAt", - "updatedAt" - ] - }, - "CreateTenantRequestDto": { - "type": "object", - "properties": { - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" } - }, - "required": ["identifier", "name"] - }, - "UpdateTenantResponseDto": { - "type": "object", - "properties": { - "_id": { "type": "string" }, - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" }, - "_environmentId": { "type": "string" }, - "createdAt": { "type": "string" }, - "updatedAt": { "type": "string" } - }, - "required": [ - "_id", - "identifier", - "_environmentId", - "createdAt", - "updatedAt" - ] - }, - "UpdateTenantRequestDto": { - "type": "object", - "properties": { - "identifier": { "type": "string" }, - "name": { "type": "string" }, - "data": { "type": "object" } - } - } - }, - "headers": { - "Content-Type": { - "required": true, - "description": "The MIME type of the response body.", - "schema": { "type": "string" }, - "example": "application/json" - }, - "RateLimit-Limit": { - "required": false, - "description": "The number of requests that the client is permitted to make per second. The actual maximum may differ when burst is enabled.", - "schema": { "type": "string" }, - "example": "100" - }, - "RateLimit-Remaining": { - "required": false, - "description": "The number of requests remaining until the next window.", - "schema": { "type": "string" }, - "example": "93" - }, - "RateLimit-Reset": { - "required": false, - "description": "The remaining seconds until a request of the same cost will be refreshed.", - "schema": { "type": "string" }, - "example": "8" - }, - "RateLimit-Policy": { - "required": false, - "description": "The rate limit policy that was used to evaluate the request.", - "schema": { "type": "string" }, - "example": "100;w=1;burst=110;comment=\"token bucket\";category=\"trigger\";cost=\"single\"" - }, - "Retry-After": { - "required": false, - "description": "The number of seconds after which the client may retry the request that was previously rejected.", - "schema": { "type": "string" }, - "example": "8" - }, - "Idempotency-Key": { - "required": false, - "description": "The idempotency key used to evaluate the request.", - "schema": { "type": "string" }, - "example": "8" - }, - "Idempotency-Replay": { - "required": false, - "description": "Whether the request was a replay of a previous request.", - "schema": { "type": "string" }, - "example": "true" - }, - "Link": { - "required": false, - "description": "A link to the documentation.", - "schema": { "type": "string" }, - "example": "https://docs.novu.co/" - } - } - }, - "externalDocs": { - "description": "Novu Documentation", - "url": "https://docs.novu.co" - }, - "x-speakeasy-name-override": [ - { "operationId": "^.*get.*", "methodNameOverride": "retrieve" }, - { "operationId": "^.*retrieve.*", "methodNameOverride": "retrieve" }, - { "operationId": "^.*create.*", "methodNameOverride": "create" }, - { "operationId": "^.*update.*", "methodNameOverride": "update" }, - { "operationId": "^.*list.*", "methodNameOverride": "list" }, - { "operationId": "^.*delete.*", "methodNameOverride": "delete" }, - { "operationId": "^.*remove.*", "methodNameOverride": "delete" } - ], - "x-speakeasy-retries": { - "strategy": "backoff", - "backoff": { - "initialInterval": 500, - "maxInterval": 30000, - "maxElapsedTime": 3600000, - "exponent": 1.5 - }, - "statusCodes": ["408", "409", "429", "5XX"], - "retryConnectionErrors": true - } -} +openapi: "3.0.0" +paths: + "/v1/environments/me": + get: + operationId: "EnvironmentsController_getCurrentEnvironment" + summary: "Get current environment" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/EnvironmentResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Environments" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "EnvironmentsController_getCurrentEnvironment", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/environments": + get: + operationId: "EnvironmentsController_listMyEnvironments" + summary: "Get environments" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/EnvironmentResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Environments" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "EnvironmentsController_listMyEnvironments", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/environments/api-keys": + get: + operationId: "EnvironmentsController_listOrganizationApiKeys" + x-speakeasy-group: "Environments.ApiKeys" + summary: "Get api keys" + x-codeSamples: [{"lang": "typescript", "label": "EnvironmentsController_listOrganizationApiKeys", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.apiKeys.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ApiKey"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Environments" + security: + - api-key: [] + "/v1/environments/api-keys/regenerate": + post: + operationId: "EnvironmentsController_regenerateOrganizationApiKeys" + x-speakeasy-name-override: "regenerate" + x-speakeasy-group: "Environments.ApiKeys" + summary: "Regenerate api keys" + x-codeSamples: [{"lang": "typescript", "label": "EnvironmentsController_regenerateOrganizationApiKeys", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.environments.apiKeys.regenerate();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + responses: + "201": + description: "Created" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ApiKey"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Environments" + security: + - api-key: [] + "/v1/execution-details": + get: + operationId: "ExecutionDetailsController_getExecutionDetailsForNotification" + summary: "Get execution details" + parameters: + - name: "notificationId" + required: true + in: "query" + schema: + type: "string" + - name: "subscriberId" + required: true + in: "query" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ExecutionDetailsResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Execution Details" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "ExecutionDetailsController_getExecutionDetailsForNotification", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.executionDetails.retrieve(\"\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/workflows": + get: + operationId: "WorkflowController_listWorkflows" + summary: "Get workflows" + description: "Workflows were previously named notification templates" + parameters: + - name: "page" + required: false + in: "query" + schema: + type: "number" + - name: "limit" + required: false + in: "query" + schema: + maximum: 100 + default: 10 + type: "number" + - name: "query" + required: false + in: "query" + description: "A query string to filter the results. It allows filtering based on either the name or trigger identifier of the workflow items." + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/WorkflowsResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_listWorkflows", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.list({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + post: + operationId: "WorkflowController_create" + summary: "Create workflow" + description: "Workflow was previously named notification template" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateWorkflowRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/WorkflowResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_create", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.create({\n name: \"\",\n notificationGroupId: \"\",\n steps: [\n {},\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/workflows/{workflowId}": + put: + operationId: "WorkflowController_updateWorkflowById" + summary: "Update workflow" + description: "Workflow was previously named notification template" + parameters: + - name: "workflowId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateWorkflowRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/WorkflowResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_updateWorkflowById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.update(\"\", {\n name: \"\",\n notificationGroupId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "WorkflowController_deleteWorkflowById" + summary: "Delete workflow" + description: "Workflow was previously named notification template" + parameters: + - name: "workflowId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/DataBooleanDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_deleteWorkflowById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + get: + operationId: "WorkflowController_getWorkflowById" + summary: "Get workflow" + description: "Workflow was previously named notification template" + parameters: + - name: "workflowId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/WorkflowResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_getWorkflowById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/workflows/variables": + get: + operationId: "WorkflowController_getWorkflowVariables" + x-speakeasy-group: "Workflows.Variables" + summary: "Get available variables" + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_getWorkflowVariables", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.variables.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Get the variables that can be used in the workflow" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/VariablesResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + "/v1/workflows/{workflowId}/status": + put: + operationId: "WorkflowController_updateActiveStatus" + x-speakeasy-group: "Workflows.Status" + summary: "Update workflow status" + x-codeSamples: [{"lang": "typescript", "label": "WorkflowController_updateActiveStatus", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflows.status.update(\"\", {\n active: false,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Workflow was previously named notification template" + parameters: + - name: "workflowId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/ChangeWorkflowStatusRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/WorkflowResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflows" + security: + - api-key: [] + "/v1/events/trigger": + post: + operationId: "EventsController_trigger" + x-speakeasy-group: "" + x-speakeasy-usage-example: {"title": "Trigger Notification Event"} + x-speakeasy-name-override: "trigger" + x-codeSamples: [{"lang": "typescript", "label": "EventsController_trigger", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.trigger({\n name: \"workflow_identifier\",\n payload: {},\n overrides: {},\n to: [\n {\n topicKey: {},\n type: \"Topic\",\n },\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + summary: "Trigger event" + description: "\n Trigger event is the main (and only) way to send notifications to subscribers. \n The trigger identifier is used to match the particular workflow associated with it. \n Additional information can be passed according the body interface below.\n " + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/TriggerEventRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/TriggerEventResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Events" + security: + - api-key: [] + "/v1/events/trigger/bulk": + post: + operationId: "EventsController_triggerBulk" + x-speakeasy-group: "" + x-speakeasy-usage-example: {"title": "Trigger Notification Events in Bulk"} + x-speakeasy-name-override: "triggerBulk" + x-codeSamples: [{"lang": "typescript", "label": "EventsController_triggerBulk", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.triggerBulk({\n events: [\n {\n name: \"workflow_identifier\",\n payload: {},\n overrides: {},\n to: [\n {\n topicKey: {},\n type: \"Topic\",\n },\n ],\n },\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + summary: "Bulk trigger event" + description: "\n Using this endpoint you can trigger multiple events at once, to avoid multiple calls to the API.\n The bulk API is limited to 100 events per request.\n " + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/BulkTriggerEventDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/TriggerEventResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Events" + security: + - api-key: [] + "/v1/events/trigger/broadcast": + post: + operationId: "EventsController_broadcastEventToAll" + x-speakeasy-group: "" + x-speakeasy-usage-example: {"title": "Broadcast Event to All"} + x-speakeasy-name-override: "triggerBroadcast" + x-codeSamples: [{"lang": "typescript", "label": "EventsController_broadcastEventToAll", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.triggerBroadcast({\n name: \"\",\n payload: {},\n overrides: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + summary: "Broadcast event to all" + description: "Trigger a broadcast event to all existing subscribers, could be used to send announcements, etc.\n In the future could be used to trigger events to a subset of subscribers based on defined filters." + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/TriggerEventToAllRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/TriggerEventResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Events" + security: + - api-key: [] + "/v1/events/trigger/{transactionId}": + delete: + operationId: "EventsController_cancel" + x-speakeasy-group: "" + x-speakeasy-usage-example: {"title": "Cancel Triggered Event"} + x-speakeasy-name-override: "cancel" + x-codeSamples: [{"lang": "typescript", "label": "EventsController_cancel", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.cancel(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + summary: "Cancel triggered event" + description: "\n Using a previously generated transactionId during the event trigger,\n will cancel any active or pending workflows. This is useful to cancel active digests, delays etc...\n " + parameters: + - name: "transactionId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/DataBooleanDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Events" + security: + - api-key: [] + "/v1/notifications": + get: + operationId: "NotificationsController_listNotifications" + summary: "Get notifications" + parameters: + - name: "channels" + required: true + in: "query" + schema: + type: "array" + items: + type: "string" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + - name: "templates" + required: true + in: "query" + schema: + type: "array" + items: + type: "string" + - name: "emails" + required: true + in: "query" + schema: + type: "array" + items: + type: "string" + - name: "search" + required: true + in: "query" + deprecated: true + schema: + type: "string" + - name: "subscriberIds" + required: true + in: "query" + schema: + type: "array" + items: + type: "string" + - name: "page" + required: false + in: "query" + schema: + default: 0 + type: "number" + - name: "transactionId" + required: false + in: "query" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/ActivitiesResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Notifications" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationsController_listNotifications", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.list({\n channels: [\n \"chat\",\n ],\n templates: [\n \"\",\n ],\n emails: [\n \"\",\n ],\n search: \"\",\n subscriberIds: [\n \"\",\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/notifications/stats": + get: + operationId: "NotificationsController_getActivityStats" + x-speakeasy-group: "Notifications.Stats" + summary: "Get notification statistics" + x-codeSamples: [{"lang": "typescript", "label": "NotificationsController_getActivityStats", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.stats.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/ActivityStatsResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Notifications" + security: + - api-key: [] + "/v1/notifications/graph/stats": + get: + operationId: "NotificationsController_getActivityGraphStats" + x-speakeasy-name-override: "graph" + x-speakeasy-group: "Notifications.Stats" + summary: "Get notification graph statistics" + x-codeSamples: [{"lang": "typescript", "label": "NotificationsController_getActivityGraphStats", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.stats.graph(4018.61);\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "days" + required: false + in: "query" + schema: + type: "number" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ActivityGraphStatesResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Notifications" + security: + - api-key: [] + "/v1/notifications/{notificationId}": + get: + operationId: "NotificationsController_getNotification" + summary: "Get notification" + parameters: + - name: "notificationId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/ActivityNotificationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Notifications" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationsController_getNotification", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.notifications.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/notification-groups": + post: + operationId: "NotificationGroupsController_createNotificationGroup" + summary: "Create workflow group" + description: "workflow group was previously named notification group" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateNotificationGroupRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/NotificationGroupResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflow groups" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationGroupsController_createNotificationGroup", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + get: + operationId: "NotificationGroupsController_listNotificationGroups" + summary: "Get workflow groups" + description: "workflow group was previously named notification group" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/NotificationGroupResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflow groups" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationGroupsController_listNotificationGroups", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/notification-groups/{id}": + get: + operationId: "NotificationGroupsController_getNotificationGroup" + summary: "Get workflow group" + description: "workflow group was previously named notification group" + parameters: + - name: "id" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/NotificationGroupResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflow groups" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationGroupsController_getNotificationGroup", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + patch: + operationId: "NotificationGroupsController_updateNotificationGroup" + summary: "Update workflow group" + description: "workflow group was previously named notification group" + parameters: + - name: "id" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateNotificationGroupRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/NotificationGroupResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflow groups" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationGroupsController_updateNotificationGroup", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.update(\"\", {\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "NotificationGroupsController_deleteNotificationGroup" + summary: "Delete workflow group" + description: "workflow group was previously named notification group" + parameters: + - name: "id" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/DeleteNotificationGroupResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Workflow groups" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "NotificationGroupsController_deleteNotificationGroup", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.workflowGroups.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/organizations": + post: + operationId: "OrganizationController_createOrganization" + summary: "Create an organization" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateOrganizationDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/OrganizationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_createOrganization", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + get: + operationId: "OrganizationController_listOrganizations" + summary: "Fetch all organizations" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/OrganizationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_listOrganizations", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + patch: + operationId: "OrganizationController_rename" + x-speakeasy-name-override: "rename" + summary: "Rename organization name" + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_rename", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.rename({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/RenameOrganizationDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/RenameOrganizationDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + "/v1/organizations/me": + get: + operationId: "OrganizationController_getSelfOrganizationData" + summary: "Fetch current organization details" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/OrganizationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_getSelfOrganizationData", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/organizations/members/{memberId}": + delete: + operationId: "OrganizationController_remove" + x-speakeasy-group: "Organizations.Members" + summary: "Remove a member from organization using memberId" + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_remove", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.members.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "memberId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/MemberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + "/v1/organizations/members": + get: + operationId: "OrganizationController_listOrganizationMembers" + x-speakeasy-group: "Organizations.Members" + summary: "Fetch all members of current organizations" + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_listOrganizationMembers", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.members.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/MemberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + "/v1/organizations/branding": + put: + operationId: "OrganizationController_updateBrandingDetails" + x-speakeasy-group: "Organizations.Branding" + summary: "Update organization branding details" + x-codeSamples: [{"lang": "typescript", "label": "OrganizationController_updateBrandingDetails", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.organizations.branding.update({\n logo: \"\",\n color: \"fuchsia\",\n fontColor: \"\",\n contentBackground: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateBrandingDetailsDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/OrganizationBrandingResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Organizations" + security: + - api-key: [] + "/v1/integrations": + get: + operationId: "IntegrationsController_listIntegrations" + summary: "Get integrations" + description: "Return all the integrations the user has created for that organization. Review v.0.17.0 changelog for a breaking change" + responses: + "200": + description: "The list of integrations belonging to the organization that are successfully returned." + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_listIntegrations", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.list();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + post: + operationId: "IntegrationsController_createIntegration" + summary: "Create integration" + description: "Create an integration for the current environment the user is based on the API key provided" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateIntegrationRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_createIntegration", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.create({\n providerId: \"\",\n channel: \"sms\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/integrations/active": + get: + operationId: "IntegrationsController_getActiveIntegrations" + x-speakeasy-name-override: "listActive" + summary: "Get active integrations" + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_getActiveIntegrations", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.listActive();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Return all the active integrations the user has created for that organization. Review v.0.17.0 changelog for a breaking change" + responses: + "200": + description: "The list of active integrations belonging to the organization that are successfully returned." + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + "/v1/integrations/webhook/provider/{providerOrIntegrationId}/status": + get: + operationId: "IntegrationsController_getWebhookSupportStatus" + x-speakeasy-group: "Integrations.Webhooks" + summary: "Get webhook support status for provider" + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_getWebhookSupportStatus", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.webhooks.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Return the status of the webhook for this provider, if it is supported or if it is not based on a boolean value" + parameters: + - name: "providerOrIntegrationId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "The status of the webhook for the provider requested" + content: + "application/json": + schema: + type: "boolean" + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + "/v1/integrations/{integrationId}": + put: + operationId: "IntegrationsController_updateIntegrationById" + summary: "Update integration" + parameters: + - name: "integrationId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateIntegrationRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "404": + description: "The integration with the integrationId provided does not exist in the database." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_updateIntegrationById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "IntegrationsController_removeIntegration" + summary: "Delete integration" + parameters: + - name: "integrationId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_removeIntegration", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/integrations/{integrationId}/set-primary": + post: + operationId: "IntegrationsController_setIntegrationAsPrimary" + x-speakeasy-name-override: "setAsPrimary" + summary: "Set integration as primary" + x-codeSamples: [{"lang": "typescript", "label": "IntegrationsController_setIntegrationAsPrimary", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.integrations.setAsPrimary(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "integrationId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/IntegrationResponseDto"} + "404": + description: "The integration with the integrationId provided does not exist in the database." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Integrations" + security: + - api-key: [] + "/v1/changes": + get: + operationId: "ChangesController_getChanges" + summary: "Get changes" + parameters: + - name: "page" + required: false + in: "query" + schema: + type: "number" + - name: "limit" + required: false + in: "query" + schema: + maximum: 100 + default: 10 + type: "number" + - name: "promoted" + required: true + in: "query" + schema: + default: "false" + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/ChangesResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Changes" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "ChangesController_getChanges", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.retrieve({\n promoted: \"false\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/changes/count": + get: + operationId: "ChangesController_getChangesCount" + x-speakeasy-name-override: "count" + summary: "Get changes count" + x-codeSamples: [{"lang": "typescript", "label": "ChangesController_getChangesCount", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.count();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/DataNumberDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Changes" + security: + - api-key: [] + "/v1/changes/bulk/apply": + post: + operationId: "ChangesController_bulkApplyDiff" + x-speakeasy-name-override: "applyBulk" + summary: "Apply changes" + x-codeSamples: [{"lang": "typescript", "label": "ChangesController_bulkApplyDiff", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.applyBulk({\n changeIds: [\n \"\",\n ],\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/BulkApplyChangeDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ChangeResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Changes" + security: + - api-key: [] + "/v1/changes/{changeId}/apply": + post: + operationId: "ChangesController_applyDiff" + x-speakeasy-name-override: "apply" + summary: "Apply change" + x-codeSamples: [{"lang": "typescript", "label": "ChangesController_applyDiff", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.changes.apply(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "changeId" + required: true + in: "path" + schema: + type: "string" + responses: + "201": + description: "Created" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/ChangeResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Changes" + security: + - api-key: [] + "/v1/subscribers": + get: + operationId: "SubscribersController_listSubscribers" + x-speakeasy-pagination: {"type": "offsetLimit", "inputs": [{"name": "page", "in": "parameters", "type": "page"}, {"name": "limit", "in": "parameters", "type": "limit"}], "outputs": {"results": "$.data.resultArray"}} + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_listSubscribers", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.list(7685.78, 10);\n\n for await (const page of result) {\n // handle page\n }\n}\n\nrun();"}] + summary: "Get subscribers" + description: "Returns a list of subscribers, could paginated using the `page` and `limit` query parameter" + parameters: + - name: "page" + required: false + in: "query" + schema: + type: "number" + - name: "limit" + required: false + in: "query" + schema: + maximum: 100 + default: 10 + type: "number" + responses: + "200": + content: + "application/json": + schema: + allOf: + - {"$ref": "#/components/schemas/PaginatedResponseDto"} + - properties: + "data": + type: "array" + items: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + post: + operationId: "SubscribersController_createSubscriber" + summary: "Create subscriber" + description: "Creates a subscriber entity, in the Novu platform. The subscriber will be later used to receive notifications, and access notification feeds. Communication credentials such as email, phone number, and 3 rd party credentials i.e slack tokens could be later associated to this entity." + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateSubscriberRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_createSubscriber", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.create({\n subscriberId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/subscribers/{subscriberId}": + get: + operationId: "SubscribersController_getSubscriber" + summary: "Get subscriber" + description: "Get subscriber by your internal id used to identify the subscriber" + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_getSubscriber", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + put: + operationId: "SubscribersController_updateSubscriber" + summary: "Update subscriber" + description: "Used to update the subscriber entity with new information" + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_updateSubscriber", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "SubscribersController_removeSubscriber" + summary: "Delete subscriber" + description: "Deletes a subscriber entity from the Novu platform" + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/DeleteSubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_removeSubscriber", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/subscribers/bulk": + post: + operationId: "SubscribersController_bulkCreateSubscribers" + x-speakeasy-name-override: "createBulk" + summary: "Bulk create subscribers" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_bulkCreateSubscribers", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.createBulk({\n subscribers: [\n \"\",\n ],\n });\n\n \n}\n\nrun();"}] + description: "\n Using this endpoint you can create multiple subscribers at once, to avoid multiple calls to the API.\n The bulk API is limited to 500 subscribers per request.\n " + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/BulkSubscriberCreateDto"} + responses: + "201": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/credentials": + put: + operationId: "SubscribersController_updateSubscriberChannel" + x-speakeasy-group: "Subscribers.Credentials" + summary: "Update subscriber credentials" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_updateSubscriberChannel", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.credentials.update(\"\", {\n providerId: 8574.78,\n credentials: {\n webhookUrl: \"\",\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Subscriber credentials associated to the delivery methods such as slack and push tokens." + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberChannelRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + patch: + operationId: "SubscribersController_modifySubscriberChannel" + x-speakeasy-name-override: "append" + x-speakeasy-group: "Subscribers.Credentials" + summary: "Modify subscriber credentials" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_modifySubscriberChannel", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.credentials.append(\"\", {\n providerId: 3462.44,\n credentials: {\n webhookUrl: \"\",\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Subscriber credentials associated to the delivery methods such as slack and push tokens.\n This endpoint appends provided credentials and deviceTokens to the existing ones." + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberChannelRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/credentials/{providerId}": + delete: + operationId: "SubscribersController_deleteSubscriberCredentials" + x-speakeasy-group: "Subscribers.Credentials" + summary: "Delete subscriber credentials by providerId" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_deleteSubscriberCredentials", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.credentials.delete(\"\", \"\");\n\n \n}\n\nrun();"}] + description: "Delete subscriber credentials such as slack and expo tokens." + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "providerId" + required: true + in: "path" + schema: + type: "string" + responses: + "204": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/online-status": + patch: + operationId: "SubscribersController_updateSubscriberOnlineFlag" + x-speakeasy-name-override: "updateOnlineFlag" + x-speakeasy-group: "Subscribers.properties" + summary: "Update subscriber online status" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_updateSubscriberOnlineFlag", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.properties.updateOnlineFlag(\"\", {\n isOnline: false,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Used to update the subscriber isOnline flag." + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberOnlineFlagRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/SubscriberResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/preferences": + get: + operationId: "SubscribersController_listSubscriberPreferences" + x-speakeasy-group: "Subscribers.Preferences" + summary: "Get subscriber preferences" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_listSubscriberPreferences", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.list(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + patch: + operationId: "SubscribersController_updateSubscriberGlobalPreferences" + x-speakeasy-name-override: "updateGlobal" + x-speakeasy-group: "Subscribers.Preferences" + summary: "Update subscriber global preferences" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_updateSubscriberGlobalPreferences", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.updateGlobal(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberGlobalPreferencesRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/preferences/{parameter}": + get: + operationId: "SubscribersController_getSubscriberPreferenceByLevel" + x-speakeasy-name-override: "retrieveByLevel" + x-speakeasy-group: "Subscribers.Preferences" + summary: "Get subscriber preferences by level" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_getSubscriberPreferenceByLevel", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.retrieveByLevel(\"Topic\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "parameter" + required: true + in: "path" + description: "the preferences level to be retrieved( Subscriber / Topic) " + schema: + type: "string" + enum: + - "Subscriber" + - "Topic" + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/GetSubscriberPreferencesResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + patch: + operationId: "SubscribersController_updateSubscriberPreference" + x-speakeasy-group: "Subscribers.Preferences" + summary: "Update subscriber preference" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_updateSubscriberPreference", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.preferences.update({\n subscriberId: \"\",\n parameter: \"\",\n updateSubscriberPreferenceRequestDto: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "parameter" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberPreferenceRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateSubscriberPreferenceResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/notifications/feed": + get: + operationId: "SubscribersController_getNotificationsFeed" + x-speakeasy-group: "Subscribers.Notifications" + summary: "Get in-app notification feed for a particular subscriber" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_getNotificationsFeed", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.notifications.retrieve({\n subscriberId: \"\",\n payload: \"btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "page" + required: false + in: "query" + schema: + type: "number" + - name: "limit" + required: false + in: "query" + schema: + maximum: 100 + default: 10 + type: "number" + - name: "read" + required: false + in: "query" + schema: + type: "boolean" + - name: "seen" + required: false + in: "query" + schema: + type: "boolean" + - name: "payload" + required: false + in: "query" + description: "Base64 encoded string of the partial payload JSON object" + example: "btoa(JSON.stringify({ foo: 123 })) results in base64 encoded string like eyJmb28iOjEyM30=" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: + allOf: + - {"$ref": "#/components/schemas/PaginatedResponseDto"} + - properties: + "data": + type: "array" + items: {"$ref": "#/components/schemas/FeedResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/notifications/unseen": + get: + operationId: "SubscribersController_getUnseenCount" + x-speakeasy-name-override: "unseenCount" + x-speakeasy-group: "Subscribers.Notifications" + summary: "Get the unseen in-app notifications count for subscribers feed" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_getUnseenCount", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.notifications.unseenCount({\n seen: false,\n subscriberId: \"\",\n limit: 2166.35,\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "seen" + required: true + in: "query" + schema: + type: "boolean" + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "limit" + required: true + in: "query" + schema: + type: "number" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/UnseenCountResponse"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/messages/mark-as": + post: + operationId: "SubscribersController_markMessagesAs" + x-speakeasy-name-override: "markAllAs" + x-speakeasy-group: "Subscribers.Messages" + summary: "Mark a subscriber messages as seen, read, unseen or unread" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_markMessagesAs", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.markAllAs(\"\", {\n messageId: \"\",\n markAs: \"seen\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/MessageMarkAsRequestDto"} + responses: + "201": + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/MessageEntity"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/messages/mark-all": + post: + operationId: "SubscribersController_markAllUnreadAsRead" + x-speakeasy-name-override: "markAll" + x-speakeasy-group: "Subscribers.Messages" + summary: "Marks all the subscriber messages as read, unread, seen or unseen. Optionally you can pass feed id (or array) to mark messages of a particular feed." + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_markAllUnreadAsRead", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.markAll(\"\", {\n markAs: \"seen\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/MarkAllMessageAsRequestDto"} + responses: + "201": + content: + "application/json": + schema: + type: "number" + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/messages/{messageId}/actions/{type}": + post: + operationId: "SubscribersController_markActionAsSeen" + x-speakeasy-name-override: "updateAsSeen" + x-speakeasy-group: "Subscribers.Messages" + summary: "Mark message action as seen" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_markActionAsSeen", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.messages.updateAsSeen({\n messageId: \"\",\n type: \"\",\n subscriberId: \"\",\n markMessageActionAsSeenDto: {\n status: \"done\",\n },\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "messageId" + required: true + in: "path" + schema: + type: "string" + - name: "type" + required: true + in: "path" + schema: {} + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/MarkMessageActionAsSeenDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/MessageResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/credentials/{providerId}/oauth/callback": + get: + operationId: "SubscribersController_chatOauthCallback" + x-speakeasy-name-override: "chatAccessOauthCallBack" + x-speakeasy-group: "Subscribers.Authentication" + summary: "Handle providers oauth redirect" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_chatOauthCallback", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.subscribers.authentication.chatAccessOauthCallBack({\n subscriberId: \"\",\n providerId: \"\",\n code: \"\",\n hmacHash: \"\",\n environmentId: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "providerId" + required: true + in: "path" + schema: {} + - name: "code" + required: true + in: "query" + schema: + type: "string" + - name: "hmacHash" + required: true + in: "query" + schema: + type: "string" + - name: "environmentId" + required: true + in: "query" + schema: + type: "string" + - name: "integrationIdentifier" + required: false + in: "query" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: + type: "object" + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/subscribers/{subscriberId}/credentials/{providerId}/oauth": + get: + operationId: "SubscribersController_chatAccessOauth" + x-speakeasy-name-override: "chatAccessOauth" + x-speakeasy-group: "Subscribers.Authentication" + summary: "Handle chat oauth" + x-codeSamples: [{"lang": "typescript", "label": "SubscribersController_chatAccessOauth", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.subscribers.authentication.chatAccessOauth({\n subscriberId: \"\",\n providerId: \"\",\n hmacHash: \"\",\n environmentId: \"\",\n });\n\n \n}\n\nrun();"}] + parameters: + - name: "subscriberId" + required: true + in: "path" + schema: + type: "string" + - name: "providerId" + required: true + in: "path" + schema: {} + - name: "hmacHash" + required: true + in: "query" + schema: + type: "string" + - name: "environmentId" + required: true + in: "query" + schema: + type: "string" + - name: "integrationIdentifier" + required: false + in: "query" + schema: + type: "string" + responses: + "200": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Subscribers" + security: + - api-key: [] + "/v1/feeds": + post: + operationId: "FeedsController_createFeed" + summary: "Create feed" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateFeedRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/FeedResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Feeds" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "FeedsController_createFeed", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.create({\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + get: + operationId: "FeedsController_getFeeds" + summary: "Get feeds" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/FeedResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Feeds" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "FeedsController_getFeeds", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.retrieve();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/feeds/{feedId}": + delete: + operationId: "FeedsController_deleteFeedById" + summary: "Delete feed" + parameters: + - name: "feedId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: + type: "array" + items: {"$ref": "#/components/schemas/FeedResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Feeds" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "FeedsController_deleteFeedById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.feeds.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/layouts": + post: + operationId: "LayoutsController_PropertyDescriptor" + x-speakeasy-name-override: "create" + summary: "Layout creation" + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_PropertyDescriptor", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.create();\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Create a layout" + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateLayoutResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + get: + operationId: "LayoutsController_listLayouts" + summary: "Filter layouts" + description: "Returns a list of layouts that can be paginated using the `page` query parameter and filtered by the environment where it is executed from the organization the user belongs to." + parameters: + - name: "page" + required: false + in: "query" + description: "Number of page for pagination" + schema: + minimum: 0 + type: "number" + - name: "pageSize" + required: false + in: "query" + description: "Size of page for pagination" + schema: + minimum: 0 + type: "number" + - name: "sortBy" + required: false + in: "query" + description: "Sort field. Currently only supported `createdAt`" + schema: + type: "string" + - name: "orderBy" + required: false + in: "query" + description: "Direction of the sorting query param" + schema: + enum: + - "ASC" + - "DESC" + type: "string" + responses: + "200": + description: "The list of layouts that match the criteria of the query params are successfully returned." + "400": + description: "Page size can not be larger than the page size limit." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_listLayouts", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.list({});\n\n \n}\n\nrun();"}] + "/v1/layouts/{layoutId}": + get: + operationId: "LayoutsController_getLayout" + summary: "Get layout" + description: "Get a layout by its ID" + parameters: + - name: "layoutId" + required: true + in: "path" + description: "The layout id" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/GetLayoutResponseDto"} + "404": + description: "The layout with the layoutId provided does not exist in the database." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_getLayout", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "LayoutsController_deleteLayout" + summary: "Delete layout" + description: "Execute a soft delete of a layout given a certain ID." + parameters: + - name: "layoutId" + required: true + in: "path" + description: "The layout id" + schema: + type: "string" + responses: + "204": + description: "The layout has been deleted correctly" + "404": + description: "The layout with the layoutId provided does not exist in the database so it can not be deleted." + "409": + description: "Either you are trying to delete a layout that is being used or a layout that is the default in the environment." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_deleteLayout", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.delete(\"\");\n\n \n}\n\nrun();"}] + patch: + operationId: "LayoutsController_updateLayout" + summary: "Update a layout" + description: "Update the name, content and variables of a layout. Also change it to be default or no." + parameters: + - name: "layoutId" + required: true + in: "path" + description: "The layout id" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateLayoutRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateLayoutResponseDto"} + "400": + description: "The payload provided or the URL param are not right." + "404": + description: "The layout with the layoutId provided does not exist in the database so it can not be updated." + "409": + description: "One default layout is needed. If you are trying to turn a default layout as not default, you should turn a different layout as default first and automatically it will be done by the system." + content: + "application/json": + schema: + example: "One default layout is required" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_updateLayout", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.layouts.update(\"\", {\n identifier: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/layouts/{layoutId}/default": + post: + operationId: "LayoutsController_setDefaultLayout" + x-speakeasy-name-override: "setAsDefault" + summary: "Set default layout" + x-codeSamples: [{"lang": "typescript", "label": "LayoutsController_setDefaultLayout", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.layouts.setAsDefault(\"\");\n\n \n}\n\nrun();"}] + description: "Sets the default layout for the environment and updates to non default to the existing default layout (if any)." + parameters: + - name: "layoutId" + required: true + in: "path" + description: "The layout id" + schema: + type: "string" + responses: + "204": + description: "The selected layout has been set as the default for the environment." + "404": + description: "The layout with the layoutId provided does not exist in the database so it can not be set as the default for the environment." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Layouts" + security: + - api-key: [] + "/v1/messages": + get: + operationId: "MessagesController_getMessages" + summary: "Get messages" + description: "Returns a list of messages, could paginate using the `page` query parameter" + parameters: + - name: "channel" + required: false + in: "query" + schema: + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + - name: "subscriberId" + required: false + in: "query" + schema: + type: "string" + - name: "transactionId" + required: false + in: "query" + schema: + type: "array" + items: + type: "string" + - name: "page" + required: false + in: "query" + schema: + default: 0 + type: "number" + - name: "limit" + required: false + in: "query" + schema: + default: 10 + type: "number" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/ActivitiesResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Messages" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "MessagesController_getMessages", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.messages.retrieve({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/messages/{messageId}": + delete: + operationId: "MessagesController_deleteMessage" + summary: "Delete message" + description: "Deletes a message entity from the Novu platform" + parameters: + - name: "messageId" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/DeleteMessageResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Messages" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "MessagesController_deleteMessage", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.messages.delete(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/messages/transaction/{transactionId}": + delete: + operationId: "MessagesController_deleteMessagesByTransactionId" + x-speakeasy-name-override: "deleteByTransactionId" + summary: "Delete messages by transactionId" + x-codeSamples: [{"lang": "typescript", "label": "MessagesController_deleteMessagesByTransactionId", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.messages.deleteByTransactionId(\"\", \"push\");\n\n \n}\n\nrun();"}] + description: "Deletes messages entity from the Novu platform using TransactionId of message" + parameters: + - name: "channel" + required: false + in: "query" + description: "The channel of the message to be deleted" + schema: + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + - name: "transactionId" + required: true + in: "path" + schema: + type: "string" + responses: + "204": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Messages" + security: + - api-key: [] + "/v1/topics": + post: + operationId: "TopicsController_createTopic" + summary: "Topic creation" + description: "Create a topic" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateTopicRequestDto"} + responses: + "201": + description: "Created" + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateTopicResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_createTopic", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.create({\n key: {},\n name: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + get: + operationId: "TopicsController_listTopics" + summary: "Filter topics" + description: "Returns a list of topics that can be paginated using the `page` query parameter and filtered by the topic key with the `key` query parameter" + parameters: + - name: "page" + required: false + in: "query" + description: "Number of page for the pagination" + schema: + minimum: 0 + default: 0 + type: "number" + - name: "pageSize" + required: false + in: "query" + description: "Size of page for the pagination" + schema: + minimum: 0 + default: 10 + type: "number" + - name: "key" + required: false + in: "query" + description: "Topic key" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/FilterTopicsResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_listTopics", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.list({});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/topics/{topicKey}/subscribers": + post: + operationId: "TopicsController_addSubscribers" + x-speakeasy-name-override: "assign" + x-speakeasy-group: "Topics.Subscribers" + summary: "Subscribers addition" + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_addSubscribers", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.subscribers.assign(\"\", {\n subscribers: [\n \"\",\n ],\n });\n\n \n}\n\nrun();"}] + description: "Add subscribers to a topic by key" + parameters: + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/AddSubscribersRequestDto"} + responses: + "204": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + "/v1/topics/{topicKey}/subscribers/{externalSubscriberId}": + get: + operationId: "TopicsController_getTopicSubscriber" + x-speakeasy-group: "Topics.Subscribers" + summary: "Check topic subscriber" + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_getTopicSubscriber", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.subscribers.retrieve(\"\", \"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Check if a subscriber belongs to a certain topic" + parameters: + - name: "externalSubscriberId" + required: true + in: "path" + description: "The external subscriber id" + schema: + type: "string" + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + responses: + "200": + content: + "application/json": + schema: {"$ref": "#/components/schemas/TopicSubscriberDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + "/v1/topics/{topicKey}/subscribers/removal": + post: + operationId: "TopicsController_removeSubscribers" + x-speakeasy-group: "Topics.Subscribers" + summary: "Subscribers removal" + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_removeSubscribers", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.subscribers.delete(\"\", {\n subscribers: [\n \"\",\n ],\n });\n\n \n}\n\nrun();"}] + description: "Remove subscribers from a topic" + parameters: + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/RemoveSubscribersRequestDto"} + responses: + "204": {} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + "/v1/topics/{topicKey}": + delete: + operationId: "TopicsController_deleteTopic" + summary: "Delete topic" + description: "Delete a topic by its topic key if it has no subscribers" + parameters: + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + responses: + "204": + description: "The topic has been deleted correctly" + "404": + description: "The topic with the key provided does not exist in the database so it can not be deleted." + "409": + description: "The topic you are trying to delete has subscribers assigned to it. Delete the subscribers before deleting the topic." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_deleteTopic", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.topics.delete(\"\");\n\n \n}\n\nrun();"}] + get: + operationId: "TopicsController_getTopic" + summary: "Get topic" + description: "Get a topic by its topic key" + parameters: + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/GetTopicResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_getTopic", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + patch: + operationId: "TopicsController_renameTopic" + x-speakeasy-name-override: "rename" + summary: "Rename a topic" + x-codeSamples: [{"lang": "typescript", "label": "TopicsController_renameTopic", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.topics.rename(\"\", {\n name: {},\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + description: "Rename a topic by providing a new name" + parameters: + - name: "topicKey" + required: true + in: "path" + description: "The topic key" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/RenameTopicRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/RenameTopicResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Topics" + security: + - api-key: [] + "/v1/tenants": + get: + operationId: "TenantController_listTenants" + x-speakeasy-pagination: {"type": "offsetLimit", "inputs": [{"name": "page", "in": "parameters", "type": "page"}, {"name": "limit", "in": "parameters", "type": "limit"}], "outputs": {"results": "$.data.resultArray"}} + x-codeSamples: [{"lang": "typescript", "label": "TenantController_listTenants", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.list(7685.78, 10);\n\n for await (const page of result) {\n // handle page\n }\n}\n\nrun();"}] + summary: "Get tenants" + description: "Returns a list of tenants, could paginated using the `page` and `limit` query parameter" + parameters: + - name: "page" + required: false + in: "query" + schema: + type: "number" + - name: "limit" + required: false + in: "query" + schema: + maximum: 100 + default: 10 + type: "number" + responses: + "200": + content: + "application/json": + schema: + allOf: + - {"$ref": "#/components/schemas/PaginatedResponseDto"} + - properties: + "data": + type: "array" + items: {"$ref": "#/components/schemas/GetTenantResponseDto"} + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Tenants" + security: + - api-key: [] + post: + operationId: "TenantController_createTenant" + summary: "Create tenant" + description: "Create tenant under the current environment" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateTenantRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/CreateTenantResponseDto"} + "409": + description: "A tenant with the same identifier is already exist." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Tenants" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TenantController_createTenant", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.create({\n identifier: \"\",\n name: \"\",\n });\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + "/v1/tenants/{identifier}": + get: + operationId: "TenantController_getTenantById" + summary: "Get tenant" + description: "Get tenant by your internal id used to identify the tenant" + parameters: + - name: "identifier" + required: true + in: "path" + schema: + type: "string" + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/GetTenantResponseDto"} + "404": + description: "The tenant with the identifier provided does not exist in the database." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Tenants" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TenantController_getTenantById", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.retrieve(\"\");\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + patch: + operationId: "TenantController_updateTenant" + summary: "Update tenant" + description: "Update tenant by your internal id used to identify the tenant" + parameters: + - name: "identifier" + required: true + in: "path" + schema: + type: "string" + requestBody: + required: true + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateTenantRequestDto"} + responses: + "200": + description: "Ok" + content: + "application/json": + schema: {"$ref": "#/components/schemas/UpdateTenantResponseDto"} + "404": + description: "The tenant with the identifier provided does not exist in the database." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Tenants" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TenantController_updateTenant", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n const result = await novu.tenants.update(\"\", {});\n\n // Handle the result\n console.log(result)\n}\n\nrun();"}] + delete: + operationId: "TenantController_removeTenant" + summary: "Delete tenant" + description: "Deletes a tenant entity from the Novu platform" + parameters: + - name: "identifier" + required: true + in: "path" + schema: + type: "string" + responses: + "204": + description: "The tenant has been deleted correctly" + "404": + description: "The tenant with the identifier provided does not exist in the database so it can not be deleted." + "409": + description: "The request could not be completed due to a conflict with the current state of the target resource." + content: + "application/json": + schema: + type: "string" + example: "Request with key 3909d656-d4fe-4e80-ba86-90d3861afcd7 is currently being processed. Please retry after 1 second" + "429": + description: "The client has sent too many requests in a given amount of time. " + content: + "application/json": + schema: + type: "string" + example: "API rate limit exceeded" + "503": + description: "The server is currently unable to handle the request due to a temporary overload or scheduled maintenance, which will likely be alleviated after some delay." + content: + "application/json": + schema: + type: "string" + example: "Please wait some time, then try again." + tags: + - "Tenants" + security: + - api-key: [] + x-codeSamples: [{"lang": "typescript", "label": "TenantController_removeTenant", "source": "import { Novu } from \"@novu/api\";\n\nconst novu = new Novu({\n apiKey: \"\",\n});\n\nasync function run() {\n await novu.tenants.delete(\"\");\n\n \n}\n\nrun();"}] + "/v1/auth/google": {} + "/v1/auth/google/callback": {} +info: + title: "Novu API" + description: "Novu REST API. Please see https://docs.novu.co/api-reference for more details." + version: "1.0" + contact: + name: "Novu Support" + url: "https://discord.gg/novu" + email: "support@novu.co" + termsOfService: "https://novu.co/terms" + license: + name: "MIT" + url: "https://opensource.org/license/mit" +tags: + - name: "Events" + description: "Events represent a change in state of a subscriber. They are used to trigger workflows, and enable you to send notifications to subscribers based on their actions." + externalDocs: + url: "https://docs.novu.co/workflows" + - name: "Subscribers" + description: "A subscriber in Novu represents someone who should receive a message. A subscriber’s profile information contains important attributes about the subscriber that will be used in messages (name, email). The subscriber object can contain other key-value pairs that can be used to further personalize your messages." + externalDocs: + url: "https://docs.novu.co/subscribers/subscribers" + - name: "Topics" + description: "Topics are a way to group subscribers together so that they can be notified of events at once. A topic is identified by a custom key. This can be helpful for things like sending out marketing emails or notifying users of new features. Topics can also be used to send notifications to the subscribers who have been grouped together based on their interests, location, activities and much more." + externalDocs: + 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." + externalDocs: + 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: + - url: "https://api.novu.co" + - url: "https://eu.api.novu.co" +components: + securitySchemes: + "api-key": + type: "apiKey" + in: "header" + name: "Authorization" + description: "API key authentication. Allowed headers-- \"Authorization: ApiKey \"." + schemas: + "DataWrapperDto": + type: "object" + properties: + "data": + type: "object" + required: + - "data" + "EnvironmentResponseDto": + type: "object" + properties: + "_id": + type: "string" + "name": + type: "string" + "_organizationId": + type: "string" + "identifier": + type: "string" + "apiKeys": + type: "array" + items: + type: "string" + "_parentId": + type: "string" + required: + - "name" + - "_organizationId" + - "identifier" + - "_parentId" + "ApiKey": + type: "object" + properties: + "key": + type: "string" + "_userId": + type: "string" + required: + - "key" + - "_userId" + "ExecutionDetailsResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_organizationId": + type: "string" + "_jobId": + type: "string" + "_environmentId": + type: "string" + "_notificationId": + type: "string" + "_notificationTemplateId": + type: "string" + "_subscriberId": + type: "string" + "_messageId": + type: "string" + "providerId": + type: "string" + "transactionId": + type: "string" + "channel": + type: "string" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + - "digest" + - "trigger" + - "delay" + - "custom" + "detail": + type: "string" + "source": + type: "string" + enum: + - "Credentials" + - "Internal" + - "Payload" + - "Webhook" + "status": + type: "string" + enum: + - "Success" + - "Warning" + - "Failed" + - "Pending" + - "Queued" + - "ReadConfirmation" + "isTest": + type: "boolean" + "isRetry": + type: "boolean" + "createdAt": + type: "string" + required: + - "_organizationId" + - "_jobId" + - "_environmentId" + - "_notificationId" + - "_notificationTemplateId" + - "_subscriberId" + - "transactionId" + - "channel" + - "detail" + - "source" + - "status" + - "isTest" + - "isRetry" + "WorkflowsResponseDto": + type: "object" + properties: + "totalCount": + type: "number" + "data": + type: "array" + items: + type: "string" + "pageSize": + type: "number" + "page": + type: "number" + required: + - "totalCount" + - "data" + - "pageSize" + - "page" + "NotificationGroup": + type: "object" + properties: + "_id": + type: "string" + "name": + type: "string" + "_environmentId": + type: "string" + "_organizationId": + type: "string" + "_parentId": + type: "string" + required: + - "name" + - "_environmentId" + - "_organizationId" + "PreferenceChannels": + type: "object" + properties: + "email": + type: "boolean" + "sms": + type: "boolean" + "in_app": + type: "boolean" + "chat": + type: "boolean" + "push": + type: "boolean" + "DigestRegularMetadata": + type: "object" + properties: + "amount": + type: "number" + "unit": + type: "string" + enum: + - "seconds" + - "minutes" + - "hours" + - "days" + - "weeks" + - "months" + "digestKey": + type: "string" + "type": + type: "string" + enum: + - "regular" + - "backoff" + "backoff": + type: "boolean" + "backoffAmount": + type: "number" + "backoffUnit": + type: "string" + enum: + - "seconds" + - "minutes" + - "hours" + - "days" + - "weeks" + - "months" + "updateMode": + type: "boolean" + required: + - "type" + "TimedConfig": + type: "object" + properties: + "atTime": + type: "string" + "weekDays": + type: "array" + items: + type: "string" + enum: + - "monday" + - "tuesday" + - "wednesday" + - "thursday" + - "friday" + - "saturday" + - "sunday" + "monthDays": + type: "array" + items: + type: "string" + "ordinal": + type: "string" + enum: + - "1" + - "2" + - "3" + - "4" + - "5" + - "last" + "ordinalValue": + type: "string" + enum: + - "day" + - "weekday" + - "weekend" + - "sunday" + - "monday" + - "tuesday" + - "wednesday" + - "thursday" + - "friday" + - "saturday" + "monthlyType": + type: "string" + enum: + - "each" + - "on" + "DigestTimedMetadata": + type: "object" + properties: + "amount": + type: "number" + "unit": + type: "string" + enum: + - "seconds" + - "minutes" + - "hours" + - "days" + - "weeks" + - "months" + "digestKey": + type: "string" + "type": + type: "string" + enum: + - "timed" + "timed": {"$ref": "#/components/schemas/TimedConfig"} + required: + - "type" + "DelayRegularMetadata": + type: "object" + properties: + "amount": + type: "number" + "unit": + type: "string" + enum: + - "seconds" + - "minutes" + - "hours" + - "days" + - "weeks" + - "months" + "type": + type: "string" + enum: + - "regular" + required: + - "type" + "DelayScheduledMetadata": + type: "object" + properties: + "type": + type: "string" + enum: + - "scheduled" + "delayPath": + type: "string" + required: + - "type" + - "delayPath" + "MessageTemplate": + type: "object" + "FieldFilterPart": + type: "object" + properties: + "field": + type: "string" + "value": + type: "string" + "operator": + type: "string" + enum: + - "LARGER" + - "SMALLER" + - "LARGER_EQUAL" + - "SMALLER_EQUAL" + - "EQUAL" + - "NOT_EQUAL" + - "ALL_IN" + - "ANY_IN" + - "NOT_IN" + - "BETWEEN" + - "NOT_BETWEEN" + - "LIKE" + - "NOT_LIKE" + - "IN" + "on": + type: "string" + enum: + - "subscriber" + - "payload" + required: + - "field" + - "value" + - "operator" + - "on" + "StepFilter": + type: "object" + properties: + "isNegated": + type: "boolean" + "type": + type: "string" + enum: + - "BOOLEAN" + - "TEXT" + - "DATE" + - "NUMBER" + - "STATEMENT" + - "LIST" + - "MULTI_LIST" + - "GROUP" + "value": + type: "string" + enum: + - "AND" + - "OR" + "children": + type: "array" + items: {"$ref": "#/components/schemas/FieldFilterPart"} + required: + - "isNegated" + - "type" + - "value" + - "children" + "NotificationStepVariant": + type: "object" + properties: + "_id": + type: "string" + "uuid": + type: "string" + "name": + type: "string" + "_templateId": + type: "string" + "active": + type: "boolean" + "shouldStopOnFail": + type: "boolean" + "template": {"$ref": "#/components/schemas/MessageTemplate"} + "filters": + type: "array" + items: {"$ref": "#/components/schemas/StepFilter"} + "_parentId": + type: "object" + "metadata": + oneOf: + - {"$ref": "#/components/schemas/DigestRegularMetadata"} + - {"$ref": "#/components/schemas/DigestTimedMetadata"} + - {"$ref": "#/components/schemas/DelayRegularMetadata"} + - {"$ref": "#/components/schemas/DelayScheduledMetadata"} + "replyCallback": + type: "object" + "NotificationStep": + type: "object" + properties: + "_id": + type: "string" + "uuid": + type: "string" + "name": + type: "string" + "_templateId": + type: "string" + "active": + type: "boolean" + "shouldStopOnFail": + type: "boolean" + "template": {"$ref": "#/components/schemas/MessageTemplate"} + "filters": + type: "array" + items: {"$ref": "#/components/schemas/StepFilter"} + "_parentId": + type: "object" + "metadata": + oneOf: + - {"$ref": "#/components/schemas/DigestRegularMetadata"} + - {"$ref": "#/components/schemas/DigestTimedMetadata"} + - {"$ref": "#/components/schemas/DelayRegularMetadata"} + - {"$ref": "#/components/schemas/DelayScheduledMetadata"} + "replyCallback": + type: "object" + "variants": {"$ref": "#/components/schemas/NotificationStepVariant"} + "NotificationTriggerVariable": + type: "object" + properties: + "name": + type: "string" + required: + - "name" + "NotificationTrigger": + type: "object" + properties: + "type": + type: "string" + enum: + - "event" + "identifier": + type: "string" + "variables": + type: "array" + items: {"$ref": "#/components/schemas/NotificationTriggerVariable"} + "subscriberVariables": + type: "array" + items: {"$ref": "#/components/schemas/NotificationTriggerVariable"} + required: + - "type" + - "identifier" + - "variables" + "WorkflowResponse": + type: "object" + properties: + "_id": + type: "string" + "name": + type: "string" + "description": + type: "string" + "active": + type: "boolean" + "draft": + type: "boolean" + "preferenceSettings": {"$ref": "#/components/schemas/PreferenceChannels"} + "critical": + type: "boolean" + "tags": + type: "array" + items: + type: "string" + "steps": + type: "array" + items: {"$ref": "#/components/schemas/NotificationStep"} + "_organizationId": + type: "string" + "_creatorId": + type: "string" + "_environmentId": + type: "string" + "triggers": + type: "array" + items: {"$ref": "#/components/schemas/NotificationTrigger"} + "_notificationGroupId": + type: "string" + "_parentId": + type: "string" + "deleted": + type: "boolean" + "deletedAt": + type: "string" + "deletedBy": + type: "string" + "notificationGroup": {"$ref": "#/components/schemas/NotificationGroup"} + "data": + type: "object" + "workflowIntegrationStatus": + type: "object" + required: + - "name" + - "description" + - "active" + - "draft" + - "preferenceSettings" + - "critical" + - "tags" + - "steps" + - "_organizationId" + - "_creatorId" + - "_environmentId" + - "triggers" + - "_notificationGroupId" + - "deleted" + - "deletedAt" + - "deletedBy" + "UpdateWorkflowRequestDto": + type: "object" + properties: + "name": + type: "string" + "tags": + type: "array" + items: + type: "string" + "description": + type: "string" + maxLength: 300 + "identifier": + type: "string" + "steps": + type: "array" + items: + type: "string" + "notificationGroupId": + type: "string" + "critical": + type: "boolean" + "preferenceSettings": {"$ref": "#/components/schemas/PreferenceChannels"} + "data": + type: "object" + required: + - "name" + - "notificationGroupId" + "DataBooleanDto": + type: "object" + properties: + "data": + type: "boolean" + required: + - "data" + "VariablesResponseDto": + type: "object" + properties: + "translations": + type: "object" + "system": + type: "object" + required: + - "translations" + - "system" + "CreateWorkflowRequestDto": + type: "object" + properties: + "name": + type: "string" + "notificationGroupId": + type: "string" + "notificationGroup": + type: "object" + "tags": + type: "array" + items: + type: "string" + "description": + type: "string" + maxLength: 1000 + "steps": + type: "array" + items: {"$ref": "#/components/schemas/NotificationStep"} + "active": + type: "boolean" + "draft": + type: "boolean" + deprecated: true + "critical": + type: "boolean" + "preferenceSettings": {"$ref": "#/components/schemas/PreferenceChannels"} + "blueprintId": + type: "string" + "data": + type: "object" + required: + - "name" + - "notificationGroupId" + - "steps" + "ChangeWorkflowStatusRequestDto": + type: "object" + properties: + "active": + type: "boolean" + required: + - "active" + "TriggerEventResponseDto": + type: "object" + properties: + "acknowledged": + type: "boolean" + description: "If trigger was acknowledged or not" + "status": + enum: + - "error" + - "trigger_not_active" + - "no_workflow_active_steps_defined" + - "no_workflow_steps_defined" + - "processed" + - "subscriber_id_missing" + - "no_tenant_found" + type: "string" + description: "Status for trigger" + "error": + description: "In case of an error, this field will contain the error message" + type: "array" + items: + type: "string" + "transactionId": + type: "string" + description: "Transaction id for trigger" + required: + - "acknowledged" + - "status" + "TopicPayloadDto": + type: "object" + properties: + "topicKey": + type: "object" + "type": + enum: + - "Subscriber" + - "Topic" + type: "string" + example: "Topic" + required: + - "topicKey" + - "type" + "TenantPayloadDto": + type: "object" + properties: + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + "SubscriberPayloadDto": + type: "object" + properties: + "subscriberId": + type: "string" + description: "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" + "email": + type: "string" + "firstName": + type: "string" + "lastName": + type: "string" + "phone": + type: "string" + "avatar": + type: "string" + description: "An http url to the profile image of your subscriber" + "locale": + type: "string" + "data": + type: "object" + "channels": + type: "array" + items: + type: "string" + required: + - "subscriberId" + "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" + "payload": + type: "object" + description: "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. \n This data will also be available when fetching the notifications feed from the API to display certain parts of the UI." + example: {"comment_id": "string", "post": {"text": "string"}} + "overrides": + type: "object" + description: "This could be used to override provider specific configurations" + example: {"fcm": {"data": {"key": "value"}}} + "to": + type: "array" + description: "The recipients list of people who will receive the notification." + items: + oneOf: + - {"$ref": "#/components/schemas/SubscriberPayloadDto"} + - type: "string" + description: "Unique identifier of a subscriber in your systems" + example: "SUBSCRIBER_ID" + - {"$ref": "#/components/schemas/TopicPayloadDto"} + "transactionId": + type: "string" + description: "A unique identifier for this transaction, we will generated a UUID if not provided." + "actor": + description: "It is used to display the Avatar of the provided actor's subscriber id or actor object.\n If a new actor object is provided, we will create a new subscriber in our system\n " + oneOf: + - type: "string" + description: "Unique identifier of a subscriber in your systems" + - {"$ref": "#/components/schemas/SubscriberPayloadDto"} + "tenant": + description: "It is used to specify a tenant context during trigger event.\n Existing tenants will be updated with the provided details.\n " + oneOf: + - type: "string" + description: "Unique identifier of a tenant in your system" + - {"$ref": "#/components/schemas/TenantPayloadDto"} + "bridgeUrl": + type: "string" + "controls": + type: "object" + required: + - "name" + - "to" + "BulkTriggerEventDto": + type: "object" + properties: + "events": + type: "array" + items: {"$ref": "#/components/schemas/TriggerEventRequestDto"} + required: + - "events" + "TriggerEventToAllRequestDto": + type: "object" + properties: + "name": + type: "string" + description: "The trigger identifier associated for the template you wish to send. This identifier can be found on the template page." + "payload": + type: "object" + description: "The payload object is used to pass additional custom information that could be used to render the template, 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." + example: {"comment_id": "string", "post": {"text": "string"}} + "overrides": + type: "object" + description: "This could be used to override provider specific configurations" + example: {"fcm": {"data": {"key": "value"}}} + "transactionId": + type: "string" + description: "A unique identifier for this transaction, we will generated a UUID if not provided." + "actor": + description: "It is used to display the Avatar of the provided actor's subscriber id or actor object.\n If a new actor object is provided, we will create a new subscriber in our system\n " + oneOf: + - type: "string" + description: "Unique identifier of a subscriber in your systems" + - {"$ref": "#/components/schemas/SubscriberPayloadDto"} + "tenant": + description: "It is used to specify a tenant context during trigger event.\n If a new tenant object is provided, we will create a new tenant.\n " + oneOf: + - type: "string" + description: "Unique identifier of a tenant in your system" + - {"$ref": "#/components/schemas/TenantPayloadDto"} + required: + - "name" + - "payload" + "ActivitiesResponseDto": + type: "object" + properties: + "hasMore": + type: "boolean" + "data": + type: "array" + items: + type: "string" + "pageSize": + type: "number" + "page": + type: "number" + required: + - "hasMore" + - "data" + - "pageSize" + - "page" + "ActivityStatsResponseDto": + type: "object" + properties: + "weeklySent": + type: "number" + "monthlySent": + type: "number" + required: + - "weeklySent" + - "monthlySent" + "ActivityGraphStatesResponse": + type: "object" + properties: + "_id": + type: "string" + "count": + type: "number" + "templates": + type: "array" + items: + type: "string" + "channels": + type: "array" + items: + type: "string" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + required: + - "_id" + - "count" + - "templates" + - "channels" + "ActivityNotificationSubscriberResponseDto": + type: "object" + properties: + "firstName": + type: "string" + "_id": + type: "string" + "lastName": + type: "string" + "email": + type: "string" + "phone": + type: "string" + required: + - "_id" + "ActivityNotificationTemplateResponseDto": + type: "object" + properties: + "_id": + type: "string" + "name": + type: "string" + "triggers": + type: "array" + items: + type: "string" + required: + - "name" + - "triggers" + "ActivityNotificationResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_environmentId": + type: "string" + "_organizationId": + type: "string" + "transactionId": + type: "string" + "createdAt": + type: "string" + "channels": + type: "string" + items: + type: "string" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + - "digest" + - "trigger" + - "delay" + - "custom" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + - "digest" + - "trigger" + - "delay" + - "custom" + "subscriber": {"$ref": "#/components/schemas/ActivityNotificationSubscriberResponseDto"} + "template": {"$ref": "#/components/schemas/ActivityNotificationTemplateResponseDto"} + "jobs": + type: "array" + items: + type: "string" + required: + - "_environmentId" + - "_organizationId" + - "transactionId" + "NotificationGroupResponseDto": + type: "object" + properties: + "_id": + type: "string" + "name": + type: "string" + "_environmentId": + type: "string" + "_organizationId": + type: "string" + "_parentId": + type: "string" + required: + - "name" + - "_environmentId" + - "_organizationId" + "CreateNotificationGroupRequestDto": + type: "object" + properties: + "name": + type: "string" + required: + - "name" + "DeleteNotificationGroupResponseDto": + 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" + "OrganizationBrandingResponseDto": + type: "object" + properties: + "direction": + enum: + - "ltr" + - "trl" + type: "string" + "logo": + type: "string" + "color": + type: "string" + "fontColor": + type: "string" + "contentBackground": + type: "string" + "fontFamily": + type: "string" + required: + - "logo" + - "color" + - "fontColor" + - "contentBackground" + "OrganizationResponseDto": + type: "object" + properties: + "name": + type: "string" + "logo": + type: "string" + "branding": {"$ref": "#/components/schemas/OrganizationBrandingResponseDto"} + "partnerConfigurations": + type: "array" + items: + type: "string" + required: + - "name" + - "branding" + "CreateOrganizationDto": + type: "object" + properties: + "name": + type: "string" + "logo": + type: "string" + "jobTitle": + enum: + - "engineer" + - "engineering_manager" + - "architect" + - "product_manager" + - "designer" + - "cxo_founder" + - "marketing_manager" + - "student" + - "cxo" + - "other" + type: "string" + "domain": + type: "string" + "language": + type: "array" + items: + type: "string" + required: + - "name" + "MemberUserDto": + type: "object" + properties: + "_id": + type: "string" + "firstName": + type: "string" + "lastName": + type: "string" + "email": + type: "string" + required: + - "_id" + - "firstName" + - "lastName" + - "email" + "MemberInviteDTO": + type: "object" + properties: + "email": + type: "string" + "token": + type: "string" + "invitationDate": + format: "date-time" + type: "string" + "answerDate": + format: "date-time" + type: "string" + "_inviterId": + type: "string" + required: + - "email" + - "token" + - "invitationDate" + - "_inviterId" + "MemberResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_userId": + type: "string" + "user": {"$ref": "#/components/schemas/MemberUserDto"} + "roles": + enum: + - "admin" + - "member" + type: "string" + "invite": {"$ref": "#/components/schemas/MemberInviteDTO"} + "memberStatus": + enum: + - "new" + - "active" + - "invited" + type: "string" + "_organizationId": + type: "string" + required: + - "_id" + - "_userId" + - "_organizationId" + "UpdateBrandingDetailsDto": + type: "object" + properties: + "logo": + type: "string" + "color": + type: "string" + "fontColor": + type: "string" + "contentBackground": + type: "string" + "fontFamily": + type: "string" + required: + - "logo" + - "color" + - "fontColor" + - "contentBackground" + "RenameOrganizationDto": + type: "object" + properties: + "name": + type: "string" + required: + - "name" + "CredentialsDto": + type: "object" + properties: + "apiKey": + type: "string" + "user": + type: "string" + "secretKey": + type: "string" + "domain": + type: "string" + "password": + type: "string" + "host": + type: "string" + "port": + type: "string" + "secure": + type: "boolean" + "region": + type: "string" + "accountSid": + type: "string" + "messageProfileId": + type: "string" + "token": + type: "string" + "from": + type: "string" + "senderName": + type: "string" + "projectName": + type: "string" + "applicationId": + type: "string" + "clientId": + type: "string" + "requireTls": + type: "boolean" + "ignoreTls": + type: "boolean" + "tlsOptions": + type: "object" + "baseUrl": + type: "string" + "webhookUrl": + type: "string" + "redirectUrl": + type: "string" + "hmac": + type: "boolean" + "serviceAccount": + type: "string" + "ipPoolName": + type: "string" + "apiKeyRequestHeader": + type: "string" + "secretKeyRequestHeader": + type: "string" + "idPath": + type: "string" + "datePath": + type: "string" + "apiToken": + type: "string" + "authenticateByToken": + type: "boolean" + "authenticationTokenKey": + type: "string" + "instanceId": + type: "string" + "alertUid": + type: "string" + "title": + type: "string" + "imageUrl": + type: "string" + "state": + type: "string" + "externalLink": + type: "string" + "channelId": + type: "string" + "phoneNumberIdentification": + type: "string" + "IntegrationResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_environmentId": + type: "string" + "_organizationId": + type: "string" + "name": + type: "string" + "identifier": + type: "string" + "providerId": + type: "string" + "channel": + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + "credentials": {"$ref": "#/components/schemas/CredentialsDto"} + "active": + type: "boolean" + "deleted": + type: "boolean" + "deletedAt": + type: "string" + "deletedBy": + type: "string" + "primary": + type: "boolean" + "conditions": + type: "array" + items: {"$ref": "#/components/schemas/StepFilter"} + required: + - "_environmentId" + - "_organizationId" + - "name" + - "identifier" + - "providerId" + - "channel" + - "credentials" + - "active" + - "deleted" + - "deletedAt" + - "deletedBy" + - "primary" + "CreateIntegrationRequestDto": + type: "object" + properties: + "name": + type: "string" + "identifier": + type: "string" + "_environmentId": + type: "string" + "providerId": + type: "string" + "channel": + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + "credentials": {"$ref": "#/components/schemas/CredentialsDto"} + "active": + type: "boolean" + description: "If the integration is active the validation on the credentials field will run" + "check": + type: "boolean" + "conditions": + type: "array" + items: {"$ref": "#/components/schemas/StepFilter"} + required: + - "providerId" + - "channel" + "UpdateIntegrationRequestDto": + type: "object" + properties: + "name": + type: "string" + "identifier": + type: "string" + "_environmentId": + type: "string" + "active": + type: "boolean" + description: "If the integration is active the validation on the credentials field will run" + "credentials": {"$ref": "#/components/schemas/CredentialsDto"} + "check": + type: "boolean" + "conditions": + type: "array" + items: {"$ref": "#/components/schemas/StepFilter"} + "ChangesResponseDto": + type: "object" + properties: + "totalCount": + type: "number" + "data": + type: "array" + items: + type: "string" + "pageSize": + type: "number" + "page": + type: "number" + required: + - "totalCount" + - "data" + - "pageSize" + - "page" + "DataNumberDto": + type: "object" + properties: + "data": + type: "number" + required: + - "data" + "ChangeResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_creatorId": + type: "string" + "_environmentId": + type: "string" + "_organizationId": + type: "string" + "_entityId": + type: "string" + "enabled": + type: "boolean" + "type": + enum: + - "Feed" + - "MessageTemplate" + - "Layout" + - "DefaultLayout" + - "NotificationTemplate" + - "NotificationGroup" + - "TranslationGroup" + - "Translation" + type: "string" + "change": + type: "object" + "createdAt": + type: "string" + "_parentId": + type: "string" + required: + - "_creatorId" + - "_environmentId" + - "_organizationId" + - "_entityId" + - "enabled" + - "type" + - "change" + - "createdAt" + "BulkApplyChangeDto": + type: "object" + properties: + "changeIds": + type: "array" + items: + type: "string" + required: + - "changeIds" + "PaginatedResponseDto": + type: "object" + properties: + "page": + type: "number" + description: "The current page of the paginated response" + "hasMore": + type: "boolean" + description: "Does the list have more items to fetch" + "pageSize": + type: "number" + description: "Number of items on each page" + "data": + description: "The list of items matching the query" + type: "array" + items: + type: "object" + required: + - "page" + - "hasMore" + - "pageSize" + - "data" + "ChannelCredentials": + type: "object" + properties: + "webhookUrl": + type: "string" + description: "Webhook url used by chat app integrations. The webhook should be obtained from the chat app provider." + "channel": + type: "string" + description: "Channel specification for Mattermost chat notifications" + "deviceTokens": + description: "Contains an array of the subscriber device tokens for a given provider. Used on Push integrations" + type: "array" + items: + type: "string" + "alertUid": + type: "string" + description: "alert_uid for grafana on-call webhook payload" + "title": + type: "string" + description: "title to be used with grafana on call webhook" + "imageUrl": + type: "string" + description: "image_url property fo grafana on call webhook" + "state": + type: "string" + description: "state property fo grafana on call webhook" + "externalUrl": + type: "string" + description: "link_to_upstream_details property fo grafana on call webhook" + required: + - "webhookUrl" + "ChannelSettings": + type: "object" + properties: + "providerId": + type: "number" + enum: + - {"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"} + description: "The provider identifier for the credentials" + "integrationIdentifier": + type: "string" + description: "The integration identifier" + "credentials": + description: "Credentials payload for the specified provider" + allOf: + - {"$ref": "#/components/schemas/ChannelCredentials"} + "_integrationId": + type: "string" + description: "Id of the integration that is used for this channel" + required: + - "providerId" + - "credentials" + - "_integrationId" + "SubscriberResponseDto": + type: "object" + properties: + "_id": + type: "string" + description: "The internal id novu generated for your subscriber, this is not the subscriberId matching your query. See `subscriberId` for that" + "firstName": + type: "string" + "lastName": + type: "string" + "email": + type: "string" + "phone": + type: "string" + "avatar": + type: "string" + "locale": + type: "string" + "subscriberId": + type: "string" + description: "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" + "channels": + description: "Channels settings for subscriber" + type: "array" + items: {"$ref": "#/components/schemas/ChannelSettings"} + "isOnline": + type: "boolean" + "lastOnlineAt": + type: "string" + "_organizationId": + type: "string" + "_environmentId": + type: "string" + "deleted": + type: "boolean" + "createdAt": + type: "string" + "updatedAt": + type: "string" + "__v": + type: "number" + required: + - "subscriberId" + - "_organizationId" + - "_environmentId" + - "deleted" + - "createdAt" + - "updatedAt" + "CreateSubscriberRequestDto": + type: "object" + properties: + "subscriberId": + type: "string" + description: "The internal identifier you used to create this subscriber, usually correlates to the id the user in your systems" + "email": + type: "string" + "firstName": + type: "string" + "lastName": + type: "string" + "phone": + type: "string" + "avatar": + type: "string" + description: "An http url to the profile image of your subscriber" + "locale": + type: "string" + "data": + type: "object" + "channels": + type: "array" + items: + type: "string" + required: + - "subscriberId" + "BulkSubscriberCreateDto": + type: "object" + properties: + "subscribers": + type: "array" + items: + type: "string" + required: + - "subscribers" + "UpdateSubscriberRequestDto": + type: "object" + properties: + "email": + type: "string" + "firstName": + type: "string" + "lastName": + type: "string" + "phone": + type: "string" + "avatar": + type: "string" + "locale": + type: "string" + "data": + type: "object" + "UpdateSubscriberChannelRequestDto": + type: "object" + properties: + "providerId": + type: "number" + enum: + - {"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"} + description: "The provider identifier for the credentials" + "integrationIdentifier": + type: "string" + description: "The integration identifier" + "credentials": + description: "Credentials payload for the specified provider" + allOf: + - {"$ref": "#/components/schemas/ChannelCredentials"} + required: + - "providerId" + - "credentials" + "UpdateSubscriberOnlineFlagRequestDto": + type: "object" + properties: + "isOnline": + type: "boolean" + required: + - "isOnline" + "DeleteSubscriberResponseDto": + 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" + "TemplateResponse": + type: "object" + properties: + "_id": + type: "string" + description: "Unique identifier of the workflow" + "name": + type: "string" + description: "Name of the workflow" + "critical": + type: "boolean" + description: "Critical templates will always be delivered to the end user and should be hidden from the subscriber preferences screen" + "triggers": + description: "Triggers are the events that will trigger the workflow." + type: "array" + items: + type: "string" + required: + - "_id" + - "name" + - "critical" + - "triggers" + "Preference": + type: "object" + properties: + "enabled": + type: "boolean" + description: "Sets if the workflow is fully enabled for all channels or not for the subscriber." + "channels": + description: "Subscriber preferences for the different channels regarding this workflow" + allOf: + - {"$ref": "#/components/schemas/PreferenceChannels"} + required: + - "enabled" + - "channels" + "UpdateSubscriberPreferenceResponseDto": + type: "object" + properties: + "template": + description: "The workflow information and if it is critical or not" + allOf: + - {"$ref": "#/components/schemas/TemplateResponse"} + "preference": + description: "The preferences of the subscriber regarding the related workflow" + allOf: + - {"$ref": "#/components/schemas/Preference"} + required: + - "template" + - "preference" + "GetSubscriberPreferencesResponseDto": + type: "object" + properties: + "template": + description: "The workflow information and if it is critical or not" + allOf: + - {"$ref": "#/components/schemas/TemplateResponse"} + "preference": + description: "The preferences of the subscriber regarding the related workflow" + allOf: + - {"$ref": "#/components/schemas/Preference"} + required: + - "preference" + "ChannelPreference": + type: "object" + properties: + "type": + type: "string" + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + description: "The type of channel that is enabled or not" + "enabled": + type: "boolean" + description: "If channel is enabled or not" + required: + - "type" + - "enabled" + "UpdateSubscriberPreferenceRequestDto": + type: "object" + properties: + "channel": + description: "The subscriber preferences for every ChannelTypeEnum for the workflow assigned." + allOf: + - {"$ref": "#/components/schemas/ChannelPreference"} + "enabled": + type: "boolean" + description: "Sets if the workflow is fully enabled for all channels or not for the subscriber." + "UpdateSubscriberGlobalPreferencesRequestDto": + type: "object" + properties: + "enabled": + type: "boolean" + description: "Enable or disable the subscriber global preferences." + "preferences": + description: "The subscriber global preferences for every ChannelTypeEnum." + type: "array" + items: {"$ref": "#/components/schemas/ChannelPreference"} + "FeedResponseDto": + type: "object" + properties: + "totalCount": + type: "number" + "hasMore": + type: "boolean" + "data": + type: "array" + items: + type: "string" + "pageSize": + type: "number" + "page": + type: "number" + required: + - "hasMore" + - "data" + - "pageSize" + - "page" + "UnseenCountResponse": + type: "object" + properties: + "count": + type: "number" + required: + - "count" + "MessageMarkAsRequestDto": + type: "object" + properties: + "messageId": + oneOf: + - type: "string" + - type: "array" + items: + type: "string" + "markAs": + enum: + - "read" + - "seen" + - "unread" + - "unseen" + type: "string" + required: + - "messageId" + - "markAs" + "MessageEntity": + type: "object" + "MarkAllMessageAsRequestDto": + type: "object" + properties: + "feedIdentifier": + oneOf: + - type: "string" + - type: "array" + items: + type: "string" + description: "Optional feed identifier or array of feed identifiers" + "markAs": + enum: + - "read" + - "seen" + - "unread" + - "unseen" + type: "string" + description: "Mark all subscriber messages as read, unread, seen or unseen" + required: + - "markAs" + "EmailBlockStyles": + type: "object" + properties: + "textAlign": + type: "string" + enum: + - "center" + - "left" + - "right" + required: + - "textAlign" + "EmailBlock": + type: "object" + properties: + "type": + enum: + - "button" + - "text" + type: "string" + "content": + type: "string" + "url": + type: "string" + "styles": {"$ref": "#/components/schemas/EmailBlockStyles"} + required: + - "type" + - "content" + "MessageCTAData": + type: "object" + properties: + "url": + type: "string" + "MessageButton": + type: "object" + properties: + "type": + type: "string" + enum: + - "primary" + - "secondary" + "content": + type: "string" + "resultContent": + type: "string" + required: + - "type" + - "content" + "MessageActionResult": + type: "object" + properties: + "payload": + type: "object" + "type": + type: "string" + enum: + - "primary" + - "secondary" + "MessageAction": + type: "object" + properties: + "status": + type: "string" + enum: + - "pending" + - "done" + "buttons": + type: "array" + items: {"$ref": "#/components/schemas/MessageButton"} + "result": {"$ref": "#/components/schemas/MessageActionResult"} + "MessageCTA": + type: "object" + properties: + "type": + type: "string" + enum: + - "redirect" + "data": {"$ref": "#/components/schemas/MessageCTAData"} + "action": {"$ref": "#/components/schemas/MessageAction"} + required: + - "data" + "MessageResponseDto": + type: "object" + properties: + "_id": + type: "string" + "_templateId": + type: "string" + "_environmentId": + type: "string" + "_messageTemplateId": + type: "string" + "_organizationId": + type: "string" + "_notificationId": + type: "string" + "_subscriberId": + type: "string" + "subscriber": {"$ref": "#/components/schemas/SubscriberResponseDto"} + "template": {"$ref": "#/components/schemas/WorkflowResponse"} + "templateIdentifier": + type: "string" + "createdAt": + type: "string" + "lastSeenDate": + type: "string" + "lastReadDate": + type: "string" + "content": + oneOf: + - {"$ref": "#/components/schemas/EmailBlock"} + - type: "string" + "transactionId": + type: "string" + "subject": + type: "string" + "channel": + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + "read": + type: "boolean" + "seen": + type: "boolean" + "email": + type: "string" + "phone": + type: "string" + "directWebhookUrl": + type: "string" + "providerId": + type: "string" + "deviceTokens": + type: "array" + items: + type: "string" + "title": + type: "string" + "cta": {"$ref": "#/components/schemas/MessageCTA"} + "_feedId": + type: "object" + nullable: true + "status": + type: "string" + enum: + - "sent" + - "error" + - "warning" + "errorId": + type: "string" + "errorText": + type: "string" + "payload": + type: "object" + description: "The payload that was used to send the notification trigger" + "overrides": + type: "object" + description: "Provider specific overrides used when triggering the notification" + required: + - "_templateId" + - "_environmentId" + - "_messageTemplateId" + - "_organizationId" + - "_notificationId" + - "_subscriberId" + - "createdAt" + - "content" + - "transactionId" + - "channel" + - "read" + - "seen" + - "cta" + - "status" + - "errorId" + - "errorText" + - "payload" + - "overrides" + "MarkMessageActionAsSeenDto": + type: "object" + properties: + "status": + enum: + - "pending" + - "done" + type: "string" + description: "Message action status" + "payload": + type: "object" + description: "Message action payload" + required: + - "status" + "CreateFeedRequestDto": + type: "object" + properties: + "name": + type: "string" + required: + - "name" + "CreateLayoutResponseDto": + type: "object" + properties: + "_id": + type: "object" + required: + - "_id" + "GetLayoutResponseDto": + type: "object" + properties: + "_id": + type: "object" + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "_creatorId": + type: "object" + "name": + type: "object" + "identifier": + type: "object" + "description": + type: "object" + "channel": + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + "content": + type: "string" + "contentType": + type: "string" + "variables": + type: "array" + items: + type: "string" + "isDefault": + type: "boolean" + "isDeleted": + type: "boolean" + "createdAt": + type: "string" + "updatedAt": + type: "string" + "_parentId": + type: "string" + required: + - "_organizationId" + - "_environmentId" + - "_creatorId" + - "name" + - "identifier" + - "channel" + - "content" + - "contentType" + - "isDefault" + - "isDeleted" + "UpdateLayoutResponseDto": + type: "object" + properties: + "_id": + type: "object" + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "_creatorId": + type: "object" + "name": + type: "object" + "identifier": + type: "object" + "description": + type: "object" + "channel": + enum: + - "in_app" + - "email" + - "sms" + - "chat" + - "push" + type: "string" + "content": + type: "string" + "contentType": + type: "string" + "variables": + type: "array" + items: + type: "string" + "isDefault": + type: "boolean" + "isDeleted": + type: "boolean" + "createdAt": + type: "string" + "updatedAt": + type: "string" + "_parentId": + type: "string" + required: + - "_organizationId" + - "_environmentId" + - "_creatorId" + - "name" + - "identifier" + - "channel" + - "content" + - "contentType" + - "isDefault" + - "isDeleted" + "UpdateLayoutRequestDto": + type: "object" + properties: + "name": + type: "object" + description: "User defined custom name and provided by the user that will name the Layout updated." + "identifier": + type: "object" + description: "User defined custom key that will be a unique identifier for the Layout updated." + "description": + type: "object" + description: "User defined description of the layout" + "content": + type: "string" + description: "User defined content for the layout." + "variables": + type: "object" + description: "User defined variables to render in the layout placeholders." + "isDefault": + type: "boolean" + description: "Variable that defines if the layout is chosen as default when creating a layout." + required: + - "identifier" + "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" + "CreateTopicRequestDto": + type: "object" + properties: + "key": + type: "object" + description: "User defined custom key and provided by the user that will be an unique identifier for the Topic created." + "name": + type: "object" + description: "User defined custom name and provided by the user that will name the Topic created." + required: + - "key" + - "name" + "AddSubscribersRequestDto": + type: "object" + properties: + "subscribers": + description: "List of subscriber identifiers that will be associated to the topic" + type: "array" + items: + type: "string" + required: + - "subscribers" + "TopicSubscriberDto": + type: "object" + properties: + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "_subscriberId": + type: "object" + "_topicId": + type: "object" + "topicKey": + type: "object" + "externalSubscriberId": + type: "object" + required: + - "_organizationId" + - "_environmentId" + - "_subscriberId" + - "_topicId" + - "topicKey" + - "externalSubscriberId" + "RemoveSubscribersRequestDto": + type: "object" + properties: + "subscribers": + description: "List of subscriber identifiers that will be removed to the topic" + type: "array" + items: + type: "string" + required: + - "subscribers" + "TopicDto": + type: "object" + properties: + "_id": + type: "object" + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "key": + type: "object" + "name": + type: "object" + "subscribers": + type: "array" + items: + type: "string" + required: + - "_organizationId" + - "_environmentId" + - "key" + - "name" + - "subscribers" + "FilterTopicsResponseDto": + type: "object" + properties: + "data": + type: "array" + items: {"$ref": "#/components/schemas/TopicDto"} + "page": + type: "number" + "pageSize": + type: "number" + "totalCount": + type: "number" + required: + - "data" + - "page" + - "pageSize" + - "totalCount" + "GetTopicResponseDto": + type: "object" + properties: + "_id": + type: "object" + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "key": + type: "object" + "name": + type: "object" + "subscribers": + type: "array" + items: + type: "string" + required: + - "_organizationId" + - "_environmentId" + - "key" + - "name" + - "subscribers" + "RenameTopicResponseDto": + type: "object" + properties: + "_id": + type: "object" + "_organizationId": + type: "object" + "_environmentId": + type: "object" + "key": + type: "object" + "name": + type: "object" + "subscribers": + type: "array" + items: + type: "string" + required: + - "_organizationId" + - "_environmentId" + - "key" + - "name" + - "subscribers" + "RenameTopicRequestDto": + type: "object" + properties: + "name": + type: "object" + description: "User defined custom name and provided by the user to rename the topic." + required: + - "name" + "GetTenantResponseDto": + type: "object" + properties: + "_id": + type: "string" + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + "_environmentId": + type: "string" + "createdAt": + type: "string" + "updatedAt": + type: "string" + required: + - "_id" + - "identifier" + - "_environmentId" + - "createdAt" + - "updatedAt" + "CreateTenantResponseDto": + type: "object" + properties: + "_id": + type: "object" + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + "_environmentId": + type: "object" + "createdAt": + type: "string" + "updatedAt": + type: "string" + required: + - "_id" + - "identifier" + - "_environmentId" + - "createdAt" + - "updatedAt" + "CreateTenantRequestDto": + type: "object" + properties: + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + required: + - "identifier" + - "name" + "UpdateTenantResponseDto": + type: "object" + properties: + "_id": + type: "string" + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + "_environmentId": + type: "string" + "createdAt": + type: "string" + "updatedAt": + type: "string" + required: + - "_id" + - "identifier" + - "_environmentId" + - "createdAt" + - "updatedAt" + "UpdateTenantRequestDto": + type: "object" + properties: + "identifier": + type: "string" + "name": + type: "string" + "data": + type: "object" + headers: + "Content-Type": + required: true + description: "The MIME type of the response body." + schema: + type: "string" + example: "application/json" + "RateLimit-Limit": + description: "The number of requests that the client is permitted to make per second. The actual maximum may differ when burst is enabled." + schema: + type: "string" + example: "100" + "RateLimit-Remaining": + description: "The number of requests remaining until the next window." + schema: + type: "string" + example: "93" + "RateLimit-Reset": + description: "The remaining seconds until a request of the same cost will be refreshed." + schema: + type: "string" + example: "8" + "RateLimit-Policy": + description: "The rate limit policy that was used to evaluate the request." + schema: + type: "string" + example: "100;w=1;burst=110;comment=\"token bucket\";category=\"trigger\";cost=\"single\"" + "Retry-After": + description: "The number of seconds after which the client may retry the request that was previously rejected." + schema: + type: "string" + example: "8" + "Idempotency-Key": + description: "The idempotency key used to evaluate the request." + schema: + type: "string" + example: "8" + "Idempotency-Replay": + description: "Whether the request was a replay of a previous request." + schema: + type: "string" + example: "true" + "Link": + description: "A link to the documentation." + schema: + type: "string" + example: "https://docs.novu.co/" +externalDocs: + description: "Novu Documentation" + url: "https://docs.novu.co" +x-speakeasy-name-override: [{"operationId": "^.*get.*", "methodNameOverride": "retrieve"}, {"operationId": "^.*retrieve.*", "methodNameOverride": "retrieve"}, {"operationId": "^.*create.*", "methodNameOverride": "create"}, {"operationId": "^.*update.*", "methodNameOverride": "update"}, {"operationId": "^.*list.*", "methodNameOverride": "list"}, {"operationId": "^.*delete.*", "methodNameOverride": "delete"}, {"operationId": "^.*remove.*", "methodNameOverride": "delete"}] +x-speakeasy-retries: {"strategy": "backoff", "backoff": {"initialInterval": 500, "maxInterval": 30000, "maxElapsedTime": 3600000, "exponent": 1.5}, "statusCodes": ["408", "409", "429", "5XX"], "retryConnectionErrors": true}