Grouping Brackets

This API endpoint allows you to group/merge HDR brackets in your order. To group the brackets in the order, you must provide the order_id and a valid API key.

You can group your images by specific amount of brackets when using the property number_of_brackets_per_image, we will group you brackets based on a visual analysis if you don't specify the number of brackets.

const apiKey = "YOUR_API_KEY";
const orderId = "ID_OF_YOUR_ORDER";
const preferences = {
  ai_version: "3.x",
  enhance: true,
  enhance_type: 'property',
  hdr: true
}
const mergeOrder = async (apiKey,orderId, preferences) => {
    return await fetch(
      `https://api.autoenhance.ai/v3/orders/${orderId}/merge`,
      {
        method: "POST",
        headers: {
          "x-api-key": apiKey,
        },
        body: JSON.stringify({
          image_name: "your-image-name",
          contentType: "image/jpeg",
          ...preferences
        }),
      }
    );
}

Merging can take between 10 seconds to 5 minutes, depending on the number of brackets that need grouping. During this time, no images will show up when you try to retrieve your order.

Once a grouping has been completed all groups will show up when you retrieve your order, and the AI will start to merge HDRs and enhance them.

Specification

Last updated