Agents
August 7, 2026 · View on GitHub
Overview
Agents are conversational assistants that receive inbound messages from connected channels and respond through a custom code bridge or a managed runtime provider. https://docs.novu.co/agents
Available Operations
- create - Create an agent
- list - List all agents
- sendReply - Send an agent reply
- retrieve - Retrieve an agent
- update - Update an agent
- delete - Delete an agent
- updateBridge - Update an agent bridge
create
Create an agent scoped to the current environment. The identifier must be unique per environment. Set runtime to managed and supply managedRuntime to provision a provider-hosted agent brain.
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.components.CreateAgentRequestDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerCreateAgentResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerCreateAgentResponse res = sdk.agents().create()
.novuAnalyticsSource("<value>")
.body(CreateAgentRequestDto.builder()
.name("<value>")
.identifier("<value>")
.build())
.call();
if (res.agentResponseDto().isPresent()) {
System.out.println(res.agentResponseDto().get());
}
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
novuAnalyticsSource | String | :heavy_check_mark: | N/A |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes |
body | CreateAgentRequestDto | :heavy_check_mark: | N/A |
Response
AgentsControllerCreateAgentResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 404, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
list
Retrieve a cursor-paginated list of agents for the current environment. Use after, before, limit, orderBy, and orderDirection query parameters.
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerListAgentsRequest;
import co.novu.models.operations.AgentsControllerListAgentsResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerListAgentsRequest req = AgentsControllerListAgentsRequest.builder()
.limit(10d)
.build();
AgentsControllerListAgentsResponse res = sdk.agents().list()
.request(req)
.call();
if (res.listAgentsResponseDto().isPresent()) {
System.out.println(res.listAgentsResponseDto().get());
}
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
request | AgentsControllerListAgentsRequest | :heavy_check_mark: | The request object to use for the request. |
Response
AgentsControllerListAgentsResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 404, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
sendReply
Send a message or side-effect into an existing agent conversation from your backend.
Use this endpoint when you are not using @novu/framework (for example Python, Go, PHP, .NET, or Java SDKs),
or when a server process outside the bridge needs to post into a live conversation.
Message actions
reply— markdown, interactive card, or tool-approval card (optionalfiles)edit— update a previously delivered message in placedeleteMessages— remove rendered platform messages (history is kept)addReactions— add emoji reactions to existing messages
Turn control
typing—{ status?: string }to set status, or"stop"to clearresolve— mark the conversation resolved (optionally with a final reply)error: true— report a customer-runtime failure (cannot combine with other actions)
Signals & tools
signals— metadata set/delete/clear, or trigger a Novu workflowtoolResults— persist tool outputs into conversation historytoolApprovalRequest— ledger a gated tool call (pair with an approval card reply)
Returns { data: { messageId, platformThreadId } } when a reply or edit is delivered;
otherwise { data: null }.
Example Usage: addReaction
package hello.world;
import co.novu.Novu;
import co.novu.models.components.AddReactionPayloadDto;
import co.novu.models.components.AgentReplyPayloadDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.addReactions(List.of(
AddReactionPayloadDto.builder()
.messageId("1712345678.123456")
.emojiName("white_check_mark")
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: cardReply
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
import java.util.Map;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(CardReplyContentDto.builder()
.card(Map.ofEntries(
Map.entry("type", "card"),
Map.entry("title", "Order #123"),
Map.entry("children", List.of(
Map.ofEntries(
Map.entry("type", "text"),
Map.entry("content", "Your order is ready for pickup.")),
Map.ofEntries(
Map.entry("type", "button"),
Map.entry("id", "confirm"),
Map.entry("label", "Confirm"),
Map.entry("style", "primary"))))))
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: deleteMessage
package hello.world;
import co.novu.Novu;
import co.novu.models.components.AgentReplyPayloadDto;
import co.novu.models.components.DeleteMessagePayloadDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.deleteMessages(List.of(
DeleteMessagePayloadDto.builder()
.messageId("1712345678.123456")
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: editMessage
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.edit(EditPayloadDto.builder()
.messageId("1712345678.123456")
.content(EditPayloadDtoContent.of(MarkdownReplyContentDto.builder()
.markdown("Updated: the report is now final.")
.build()))
.build())
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: markdownReply
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(MarkdownReplyContentDto.builder()
.markdown("**Report ready.** Your weekly summary is attached.")
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: metadataSignal
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
import java.util.Map;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.signals(List.of(
Signal.of(TriggerSignalDto.builder()
.type(TriggerSignalDtoType.TRIGGER)
.workflowId("order-shipped")
.to(TriggerSignalDtoTo2.of("subscriber-123"))
.payload(Map.ofEntries(
Map.entry("orderId", "ORD-42")))
.build())))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: replyWithFile
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(MarkdownReplyContentDto.builder()
.markdown("Here is your report.")
.files(List.of(
FileRefDto.builder()
.filename("report.pdf")
.mimeType("application/pdf")
.url("https://example.com/files/report.pdf")
.build()))
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: resolveConversation
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(MarkdownReplyContentDto.builder()
.markdown("Glad that helped — marking this as resolved.")
.build()))
.resolve(ResolveDto.builder()
.summary("Answered billing question about invoice INV-42.")
.build())
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: toolApprovalRequest
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.Map;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(ToolApprovalCardReplyContentDto.builder()
.toolApprovalCard(Map.ofEntries(
Map.entry("type", "tool-approval-card"),
Map.entry("title", "Approve refund?"),
Map.entry("subtitle", "issue_refund · ORD-42 · \$25.00"),
Map.entry("approveLabel", "Approve"),
Map.entry("denyLabel", "Deny")))
.build()))
.toolApprovalRequest(ToolApprovalRequestPayloadDto.builder()
.approvalId("apr_01HZX")
.toolCallId("call_refund_1")
.name("issue_refund")
.input(Map.ofEntries(
Map.entry("orderId", "ORD-42"),
Map.entry("amountCents", 2500L)))
.build())
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: toolResult
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.reply(Reply.of(MarkdownReplyContentDto.builder()
.markdown("Your order **ORD-42** has shipped and should arrive by July 16.")
.build()))
.toolResults(List.of(
ToolResultDto.builder()
.toolCallId("call_abc123")
.toolName("lookup_order")
.output(Output.builder()
.build())
.preview("Order ORD-42 is shipped")
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: triggerWorkflow
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
import java.util.List;
import java.util.Map;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.signals(List.of(
Signal.of(TriggerSignalDto.builder()
.type(TriggerSignalDtoType.TRIGGER)
.workflowId("order-shipped")
.to(TriggerSignalDtoTo2.of("subscriber-123"))
.payload(Map.ofEntries(
Map.entry("orderId", "ORD-42")))
.build())))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: turnError
package hello.world;
import co.novu.Novu;
import co.novu.models.components.AgentReplyPayloadDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.error(true)
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: typingStart
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.typing(Typing.of(TypingStatusDto.builder()
.status("Looking up your order…")
.build()))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Example Usage: typingStop
package hello.world;
import co.novu.Novu;
import co.novu.models.components.*;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentReplyControllerHandleAgentReplyHandlerResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentReplyControllerHandleAgentReplyHandlerResponse res = sdk.agents().sendReply()
.agentId("support-agent")
.body(AgentReplyPayloadDto.builder()
.conversationId("64f5a1c2e8b7a3d9f0c1b2a3")
.integrationIdentifier("slack-support")
.typing(Typing.of(TypingEnum.STOP))
.build())
.call();
if (res.object().isPresent()) {
System.out.println(res.object().get());
}
}
}
Parameters
| Parameter | Type | Required | Description | Example |
|---|---|---|---|---|
agentId | String | :heavy_check_mark: | Agent identifier (slug) for the agent that owns the conversation. | support-agent |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes | |
body | AgentReplyPayloadDto | :heavy_check_mark: | Reply payload. Provide at least one action: reply, edit, resolve, signals, toolResults, toolApprovalRequest, addReactions, deleteMessages, typing, or error. See named examples for common shapes used by server-side SDKs. |
Response
AgentReplyControllerHandleAgentReplyHandlerResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
retrieve
Retrieve an agent by its external identifier (not the internal MongoDB id).
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerGetAgentResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerGetAgentResponse res = sdk.agents().retrieve()
.identifier("<value>")
.call();
if (res.agentResponseDto().isPresent()) {
System.out.println(res.agentResponseDto().get());
}
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
identifier | String | :heavy_check_mark: | N/A |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes |
Response
AgentsControllerGetAgentResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
update
Update an agent by its external identifier.
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.components.UpdateAgentRequestDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerUpdateAgentResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerUpdateAgentResponse res = sdk.agents().update()
.identifier("<value>")
.body(UpdateAgentRequestDto.builder()
.build())
.call();
if (res.agentResponseDto().isPresent()) {
System.out.println(res.agentResponseDto().get());
}
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
identifier | String | :heavy_check_mark: | N/A |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes |
body | UpdateAgentRequestDto | :heavy_check_mark: | N/A |
Response
AgentsControllerUpdateAgentResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
delete
Delete an agent by identifier, remove all agent-integration links, and clear the agent assignment from any workflows that reference it. For managed-runtime agents, pass deleteFromProvider=true to also archive the agent on the provider side (e.g. Anthropic). By default only the Novu record is deleted and the provider agent is left intact.
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerDeleteAgentResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerDeleteAgentResponse res = sdk.agents().delete()
.identifier("<value>")
.deleteFromProvider("<value>")
.call();
// handle response
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
identifier | String | :heavy_check_mark: | N/A |
deleteFromProvider | String | :heavy_check_mark: | N/A |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes |
Response
AgentsControllerDeleteAgentResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |
updateBridge
Update the bridge URL configuration for an agent. Used by the CLI to register dev tunnel URLs. Refuses to activate dev bridges on production environments.
Example Usage
package hello.world;
import co.novu.Novu;
import co.novu.models.components.UpdateAgentBridgeRequestDto;
import co.novu.models.errors.ErrorDto;
import co.novu.models.errors.ValidationErrorDto;
import co.novu.models.operations.AgentsControllerUpdateAgentBridgeResponse;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws ErrorDto, ValidationErrorDto, Exception {
Novu sdk = Novu.builder()
.secretKey("YOUR_SECRET_KEY_HERE")
.build();
AgentsControllerUpdateAgentBridgeResponse res = sdk.agents().updateBridge()
.identifier("<value>")
.body(UpdateAgentBridgeRequestDto.builder()
.build())
.call();
if (res.agentResponseDto().isPresent()) {
System.out.println(res.agentResponseDto().get());
}
}
}
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
identifier | String | :heavy_check_mark: | N/A |
idempotencyKey | Optional<String> | :heavy_minus_sign: | A header for idempotency purposes |
body | UpdateAgentBridgeRequestDto | :heavy_check_mark: | N/A |
Response
AgentsControllerUpdateAgentBridgeResponse
Errors
| Error Type | Status Code | Content Type |
|---|---|---|
| models/errors/ErrorDto | 414 | application/json |
| models/errors/ErrorDto | 400, 401, 403, 405, 409, 413, 415 | application/json |
| models/errors/ValidationErrorDto | 422 | application/json |
| models/errors/ErrorDto | 500 | application/json |
| models/errors/APIException | 4XX, 5XX | */* |