Developer Docs - Helix - Endpoints

Endpoints are the fundamental units of work for your applications, encapsulating the logic called from the client. Below is the editing panel for an endpoint.

Each of the properties of the endpoint are described in more detail below:

Calling The Endpoint

The full route to the endpoint is:

/api/v2/lava-app/1/{application-slug}/{endpoint-slug}

We've simplified this though when using the Lava Application Content block. Appending a ^ allows you to just use the application and endpoint slug.

^/{application-slug}/{endpoint-slug}

HTTP Methods

You might wonder when to use which HTTP method. Generally, the choice of method doesn’t significantly impact operations, but it's crucial to avoid using the GET method for editing database data, as GET requests can be less secure and easily initiated by third-party links. Typically, the following patterns are observed:

Lava Merge Fields

When writing Lava for your endpoints you have access to the following merge fields:

Special Lava Considerations for Endpoints

In most cases, Lava within your endpoints doesn't require any special handling. However, there are a few exceptions you should keep in mind.