Skip to content

Your First Endpoint

Endpoints in AireGlu are where the magic happens. At the most basic level they accept data, then do something with it. This could be as simple as sending an email, or as a complex multi-system processing task.

To keep things simple, for your first endpoint we'll take in some data and use it to create and send an email. Head over to the Endpoints page using the top menu, and click the plus button at the top to add a new endpoint.

Endpoints

The first step is to define our endpoint name and tasks it will perform. We'll go through and add details to these tasks later. The Endpoint Name is important. This should be descriptive, but not too long because it's used in the url for the endpoint. Task names should also be descriptive for your reference later. In our case, we'll use email-test-A as an endpoint name. We also create a single Email type task called Send an email. Hit the Next button at the bottom to continue.

Endpoints

Our next step is to define our input data. You can type this yourself, or copy and paste the output of your application. For this, we only need something simple, so paste the following into the left side. You should ensure that the format selected is JSON.

json
{
  "name": "John Smith",
  "email": "john@example.com"
}

Hit the Next button when you're ready.

Endpoints

Now we define our email. Click into the To textbox, and then click the left arrow next to email on the right. This will tell AireGlu that you want to use the email field from our input data as the recipient. Add a subject, and the message of your email. In both of these fields you can click the arrow next to a field to add that data. Add the name field to the body to give the message a personal feel.

Scroll down and click Next when you're done.

Endpoints

Finally, we're ready to deploy. Make a note of the Endpoint URL - you'll need to have your app point at this. Select your environments, and click Save & Deploy to finish!

Endpoints

Use your app to send your data to your new Endpoint, and then check your email! Congratulations on completing your first AireGlu Endpoint!

Check out the Endpoints documentation for more detailed examples, and explanations of the other tasks and formats you can use.