Skip to content

Commit 080f65f

Browse files
marijahorvat171ivicac
authored andcommitted
2040 - add version, help and fix descriptions
1 parent d067079 commit 080f65f

6 files changed

Lines changed: 15 additions & 6 deletions

File tree

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/BrevoComponentHandler.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ public class BrevoComponentHandler implements ComponentHandler {
4040
.description(
4141
"Brevo is an email marketing platform that offers a cloud-based marketing communication software suite " +
4242
"with transactional email, marketing automation, customer-relationship management and more.")
43+
.customAction(true)
44+
.customActionHelp("", "https://developers.brevo.com/docs/quickstart-reference")
4345
.icon("path:assets/brevo.svg")
4446
.categories(ComponentCategory.MARKETING_AUTOMATION)
4547
.connection(BrevoConnection.CONNECTION_DEFINITION)
@@ -52,7 +54,8 @@ public class BrevoComponentHandler implements ComponentHandler {
5254
.clusterElements(
5355
tool(BrevoCreateContactAction.ACTION_DEFINITION),
5456
tool(BrevoUpdateContactAction.ACTION_DEFINITION),
55-
tool(BrevoSendTransactionalEmailAction.ACTION_DEFINITION));
57+
tool(BrevoSendTransactionalEmailAction.ACTION_DEFINITION))
58+
.version(1);
5659

5760
@Override
5861
public ComponentDefinition getDefinition() {

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/action/BrevoCreateContactAction.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ public class BrevoCreateContactAction {
4343
public static final ModifiableActionDefinition ACTION_DEFINITION = action("createContact")
4444
.title("Create Contact")
4545
.description("Creates new contact.")
46+
.help("", "https://docs.bytechef.io/reference/components/brevo_v1#create-contact")
4647
.properties(
4748
string(EMAIL)
4849
.label("Email")
@@ -84,9 +85,9 @@ public static Object perform(Parameters inputParameters, Parameters connectionPa
8485
private static Map<String, String> createAttributesMap(Parameters inputParameters) {
8586
Map<String, String> attributesMap = new HashMap<>();
8687

87-
String firstNAme = inputParameters.getString(FIRST_NAME);
88-
if (firstNAme != null) {
89-
attributesMap.put(FIRST_NAME, firstNAme);
88+
String firstName = inputParameters.getString(FIRST_NAME);
89+
if (firstName != null) {
90+
attributesMap.put(FIRST_NAME, firstName);
9091
}
9192

9293
String lastName = inputParameters.getString(LAST_NAME);

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/action/BrevoSendTransactionalEmailAction.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,8 @@ enum ContentType {
5555

5656
public static final ModifiableActionDefinition ACTION_DEFINITION = action("sendTransactionalEmail")
5757
.title("Send Transactional Email")
58-
.description("Sends and email from your Brevo account.")
58+
.description("Sends an email from your Brevo account.")
59+
.help("", "https://docs.bytechef.io/reference/components/brevo_v1#send-transactional-email")
5960
.properties(
6061
string(SENDER_EMAIL)
6162
.label("Sender Email")

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/action/BrevoUpdateContactAction.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ public class BrevoUpdateContactAction {
3636

3737
public static final ModifiableActionDefinition ACTION_DEFINITION = action("updateContact")
3838
.title("Update Contact")
39-
.description("Updates existing contact.")
39+
.description("Updates an existing contact.")
40+
.help("", "https://docs.bytechef.io/reference/components/brevo_v1#update-contact")
4041
.properties(
4142
string(EMAIL)
4243
.label("Email")

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/connection/BrevoConnection.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ public class BrevoConnection {
3232

3333
public static final ModifiableConnectionDefinition CONNECTION_DEFINITION = connection()
3434
.baseUri((connectionParameters, context) -> "https://api.brevo.com/v3")
35+
.help("", "https://docs.bytechef.io/reference/components/brevo_v1#connection-setup")
36+
.version(1)
3537
.authorizations(
3638
authorization(AuthorizationType.API_KEY)
3739
.title("API Key")

server/libs/modules/components/brevo/src/main/java/com/bytechef/component/brevo/trigger/BrevoTransactionalEmailOpenedTrigger.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ public class BrevoTransactionalEmailOpenedTrigger {
4141
public static final ModifiableTriggerDefinition TRIGGER_DEFINITION = trigger("transactionalEmailOpened")
4242
.title("Transactional Email Opened")
4343
.description("Triggers when transactional email is opened.")
44+
.help("", "https://docs.bytechef.io/reference/components/brevo_v1#transactional-email-opened")
4445
.type(TriggerType.DYNAMIC_WEBHOOK)
4546
.output()
4647
.webhookEnable(BrevoTransactionalEmailOpenedTrigger::webhookEnable)

0 commit comments

Comments
 (0)