# Bearer Authorization in Custom API integration

**URL:** <https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105>\
**Category:** Beats\
**Created:** [February 26, 2025, 8:29pm UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105 "2025-02-26T20:29:34Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![tsturg15](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsturg15/32/141659_2.png) [@tsturg15](https://discuss.elastic.co/u/tsturg15)\
**Post date:** [February 26, 2025, 8:29pm UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105/1 "2025-02-26T20:29:34Z")

</div>

I am working with an API that only provides Bearer token's. Is it possible to create a custom API integration using this API if they only provide bearer authorization through the headers and not basic, digest, or Oauth2?

---

<div class="post-metadata">

**Author:** ![TimV](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timv/32/13162_2.png) [@TimV](https://discuss.elastic.co/u/TimV)\
**Post date:** [February 27, 2025, 3:47am UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105/2 "2025-02-27T03:47:58Z")

</div>

Can you clarify what specifically you mean by a "Custom API integration".

The Elastic product suite contains a variety of integration points, and we can only help if we know which one you're trying to use.

---

<div class="post-metadata">

**Author:** ![tsturg15](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsturg15/32/141659_2.png) [@tsturg15](https://discuss.elastic.co/u/tsturg15)\
**Post date:** [February 27, 2025, 5:05am UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105/3 "2025-02-27T05:05:09Z")

</div>

Apologies, I mean the Custom API input Integration documented here: [Custom API input integration | Elastic integrations | Elastic](https://www.elastic.co/guide/en/integrations/current/httpjson.html)

Within the configuration of this integration it only provides the option for Basic Auth and OAuth2.

I've tried the following within the Request Transform section to send the bearer token in the header during the request but I'm not seeing it being passed when viewing the logs.

```auto
request.transforms:
  - set:
      target: header.Authorization
      value: "Bearer auth_token"

```

Is it possible to use an API that uses Bearer Authorization with this integration? If not, is it possible with the CEL Custom API input integration? [CEL Custom API input integration | Elastic integrations | Elastic](https://www.elastic.co/guide/en/integrations/current/cel.html)

---

<div class="post-metadata">

**Author:** ![TimV](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/timv/32/13162_2.png) [@TimV](https://discuss.elastic.co/u/TimV)\
**Post date:** [February 28, 2025, 1:54am UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105/4 "2025-02-28T01:54:51Z")

</div>

In that case, I'm going to move this to the beats forum, because that sort of integration actually runs on top of the beats HTTP input

---

<div class="post-metadata">

**Author:** ![slarosa-rbc](https://avatars.discourse-cdn.com/v4/letter/s/a183cd/32.png) [@slarosa-rbc](https://discuss.elastic.co/u/slarosa-rbc)\
**Post date:** [December 18, 2025, 6:57pm UTC](https://discuss.elastic.co/t/bearer-authorization-in-custom-api-integration/375105/5 "2025-12-18T18:57:48Z")

</div>

Hello!

I need to do this same thing - did you ever figure it out?
