Developer Docs

Bot-written reusable components and services

One of the most popular principles of software development is DRY (Don’t repeat yourself) and a common solution to this is to create reusable components within your application. There are many benefits of reusable components. Some of these benefits include ease of development due to consistent interfaces and, in many cases, reusable functionality and appearance.

Codebots amplifies the amount of resuablility within your applications through use of What is an extension?, such as Forms extension overview, in order to maximise the value of a developers time. In addition to these extensions, a Codebots application also comes packaged with a collection of useful services and components that can be leveraged in custom code.

UI components

The codebot writes a number of UI components which you can use when developing your application. These components are simple, reusable, and will allow you to develop your application more quickly and with higher quality. In a C#Bot application, these components can be found at clientside/src/Views/Components, and in a SpringBot application they can be found at clientside/src/app/lib/components. These library components include the following components and more:

These components, as well as others which weren’t mentioned can be added into your templates using the same method you would use to add components you have created. Each of these components also have a number of inputs which you can modify to customise the components in a way that works for your specific requirements.

Services

A Codebots application also comes with services which can be used in your custom code to add additional functionality to your application. The services that are discussed here are available in both SpringBot and C#Bot applications.

Email

The email service allows for emails to be sent using the target application. By default, this service is used for functionality such as sending forgotten and reset password emails, however you can utilise it in custom code in your application to fulfil any requirements for sending emails that you might have. In a C#Bot application, the email service can be found at serverside/src/Services/EmailService.cs, and in a SpringBot application it can be found at serverside/src/main/java/[ApplicationName]/lib/services/email.

Scheduled tasks

The scheduled tasks service allows you to define tasks to be run at a specified time or frequency. You can learn more about scheduled tasks in a Springbot application Custom Scheduled Tasks with SpringBot, and information about using scheduled tasks in C#Bot applications can be found C#Bot: Custom Scheduled Tasks.

Was this article helpful?

Thanks for your feedback!

If you would like to tell us more, please click on the link below to send us a message with more details.

Tool:

Generate

Iterate

Bot:

C#Bot

SpringBot

On this page

New to Codebots?

We know our software can be complicated, so we are always happy to have a chat if you have any questions.