To retrieve a list of aliases for a specific deployment using the Esadax API, follow these steps:
Construct the URL: Replace {id} with your deployment ID, such as dpl_FjvFJncQHQcZMznrUm9EoB8sFuPa.
Include Query Parameters: Add slug and teamId if necessary to specify the team or project.
Set Headers: Include the Authorization header with your Bearer token.
Use fetch Method: Send a GET request using JavaScript's fetch function.
Here's the cURL command:
await fetch("https://api.esadax.com/v2/deployments/dpl_FjvFJncQHQcZMznrUm9EoB8sFuPa/aliases?slug=SOME_STRING_VALUE&teamId=SOME_STRING_VALUE", {
headers: {
"Authorization": "Bearer <TOKEN>",
"method": "get"
}
});