Skip to content

[Refactor] Allow request specific headers in ApiRequest object

MR: feat: custom headers in PostEndpoint createRequest (!360 - merged)

Description

In !314 (merged) we needed to set specific headers for a certain request. Right now, that's only possible at factory time when we create the GitLabApiClient... Let's add support for passing headers as part of the ApiRequest and refactor this line https://gitlab.com/gitlab-org/gitlab-web-ide/-/blob/f3abf075b3018dbe8b819b7a6862e00c936afc79/packages/web-ide/src/cleanExtensions.ts#L77

Context

The following discussion from !314 (merged) should be addressed:

  • @pslaughter started a discussion:

    todo (non-blocking): I'll create an issue so we can move these headers to the request object itself 👀

Edited by Cindy Halim