Skip to content

Commit

Permalink
[Enterprise Search][Search application]Fix Create Api key url (elasti…
Browse files Browse the repository at this point in the history
…c#159519)

## Summary

Fixes regression issue, probably created when `engines` were renamed to
`Search applications` in backend. The Create api key `POST` request was
requesting to incorrect url. Replaced with correct url in this PR.
  • Loading branch information
saarikabhasi authored Jun 12, 2023
1 parent 662f11e commit e03d901
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ describe('GenerateEngineApiKeyLogic', () => {
});
await nextTick();
expect(http.post).toHaveBeenCalledWith(
'/internal/enterprise_search/engines/puggles/api_key',
'/internal/enterprise_search/search_applications/puggles/api_key',
{
body: JSON.stringify({
keyName: 'puggles read only key',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export const generateEngineApiKey = async ({
engineName: string;
keyName: string;
}) => {
const route = `/internal/enterprise_search/engines/${engineName}/api_key`;
const route = `/internal/enterprise_search/search_applications/${engineName}/api_key`;

return await HttpLogic.values.http.post<APIKeyResponse>(route, {
body: JSON.stringify({
Expand Down

0 comments on commit e03d901

Please sign in to comment.