Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

kong gateway add headers

I want to add some headers to my incoming rest api requests with kong gateway. In the kong admin UI, I set these parametes :

config.add.headers: myheader: $(consumer_id)

myheader is a name for new header and I want to set variable of consumer_id value in these header. but after this configuration , kong gives me a empty value. I also tried ${consumer_id} and etc ... but none of these variables worked.!

So the question is: what's the VARIABLE syntaxs of consumer_id or custom_id and ... too call in kong gateway.

thx BR

like image 628
pheshmati Avatar asked Jan 26 '26 11:01

pheshmati


1 Answers

finally I found the correct header from network dump, and replace it with My required header.

the right header for my case was : X-Consumer-Custom-ID

like image 117
pheshmati Avatar answered Jan 29 '26 13:01

pheshmati



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!