fix(endpoints): use the post method for batch delete API operations [BE-11573] (#397)

This commit is contained in:
viktigpetterr
2025-02-06 18:17:13 +01:00
parent 157c83deee
commit 3e5ec79b21
3 changed files with 28 additions and 6 deletions

View File

@@ -55,11 +55,11 @@ async function deleteEnvironments(
environments: { id: EnvironmentId; deleteCluster?: boolean }[]
) {
try {
const { data } = await axios.delete<{
const { data } = await axios.post<{
deleted: EnvironmentId[];
errors: EnvironmentId[];
} | null>(buildUrl(), {
data: { endpoints: environments },
} | null>(buildUrl(undefined, 'delete'), {
endpoints: environments,
});
return data;
} catch (e) {