Questions tagged [google-api-gateway]

66 questions
8
votes
2 answers

Google API Gateway: Provide API key in header

I'm trying to setup Google API Gateway to use an API key that callers send in the header. My api config yaml looks like this: ... securityDefinitions: api_key_header: type: apiKey name: key in: header api_key_query: type: apiKey …
Slava Medvediev
  • 1,431
  • 19
  • 35
3
votes
3 answers

Google API Gateway: Authorization Header not forwarded

I have a Google Cloud API gateway deployed to send requests to a cloud run service. The cloud run service hosts a laravel docker container image and to authenticate with my authenticated pages, I need to send an Authorization header (Authorization:…
2
votes
1 answer

Firebase Hosting rewrite path to use GCP API Gateway as backend for SPA

I am trying to find a way to connect the backend (GCP API Gateway) to our Angular app hosted on firebase. The goal is to route requests on myapp.com/api to the API Gateway. All other routes should server our SPA. I know there is a possibility to…
2
votes
0 answers

GCP API Gateway How to config 50 to 60 endpoints using API Gateway?

Have multiple API to be configured using API Gateway. But config file will be larger and more over it is not possible to configure each and every API in API Gateway. Is there any other ways are there for it ?. I am using cloud functions and clouds…
2
votes
1 answer

GCP API Gateway to secure internal/external communication for API deployed on App Engine

I am building a microservice architecture and I need help with internal/external communication. I have microservices which are deployed on GCP App Engine Flex and have GCP API Gateway that sits in front of them. API Gateway handles external…
2
votes
2 answers

GCP API gateway returning 403 saying managed service "is not enabled for the project"

Trying to access a public cloud run service and not sure why I keep getting this error message ({"message":"PERMISSION_DENIED:API basic-express-api-1yy1jgrw4nwy2.apigateway.chrome-courage-336400.cloud.goog is not enabled for the…
2
votes
1 answer

How to get the jwt payload in route authenticated by api gateway inside the function?

I have a gateway configured for my project, and i added the security options in the route and it's works: My function thats generate the jwt token: def generate_jwt(): payload = {"iat": iat, "exp": exp, "iss": iss, "aud": aud, "sub": iss,…
2
votes
0 answers

API Gateway modifies backendRequest hostname to be "backend-cluster-dev.equipment.example.com:443" instead of just "dev.equipment.example.com:443"

Can't understand why API Gateway prepends the hostname with "backend-cluster" prefix. The log of the gateway on the request looks like below: { httpRequest: { latency: "0.113s" protocol: "HTTP/1.1" remoteIp:…
2
votes
1 answer

Can not delete google api gateway config file

I was trying to delete a config file from the google api gateway service from the UI and also from the command line. But they are saying target config file is in use but I couldn't find it anywhere neither in UI nor in the result of gcloud command…
xalien
  • 123
  • 1
  • 8
2
votes
1 answer

GCP API Gateway: Path parameters are being passed as query params

I'm trying to use GCP API Gateway to create a single endpoint for a couple of my backend services (A,B,C,D), each with their own path structure. I have the Gateway configured for one of the services as follows: swagger: '2.0' info: title: …</div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/api" class="post-tag grid--cell" title="show questions tagged 'api'" rel="tag">api</a> <a href="../../questions/tagged/google-cloud-platform" class="post-tag grid--cell" title="show questions tagged 'google-cloud-platform'" rel="tag">google-cloud-platform</a> <a href="../../questions/tagged/api-gateway" class="post-tag grid--cell" title="show questions tagged 'api-gateway'" rel="tag">api-gateway</a> <a href="../../questions/tagged/google-cloud-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-cloud-api-gateway'" rel="tag">google-cloud-api-gateway</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Sep 22 '21 at 04:20">asked Sep 22 '21 at 04:20</time> <a href="../../users/6653295/nissan" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/6653295.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="Nissan " /> </a> <div class="s-user-card--info"> <a href="../../users/6653295/nissan" class="s-user-card--link">Nissan </a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">466</li> <li class="s-award-bling s-award-bling__gold" title="1 gold badge">1</li> <li class="s-award-bling s-award-bling__silver" title="4 silver badge">4</li> <li class="s-award-bling s-award-bling__bronze" title="12 bronze badge">12</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="mln24"> <div class="question-summary" id="question-summary-69094248"> <div class="statscontainer"> <div class="stats"> <div class="vote"> <div class="votes"> <span class="vote-count-post"><strong>2</strong></span> <div class="viewcount">votes</div> </div> </div> <div class="status "> <strong>1</strong> answer </div> </div> </div> <div class="summary"> <h3><a href="../../questions/69094248/google-api-gateway-streaming-data-in-response" class="question-hyperlink">Google API Gateway - streaming data in response</a></h3> <div class="excerpt">I'm using Google Cloud API Gateway in order to have single point of entry to my backed-end services and also for adding api-key security level. And I have one endpoint which should return data as a stream chunk by chunk(content-type is audio/mpeg).…</div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/google-cloud-platform" class="post-tag grid--cell" title="show questions tagged 'google-cloud-platform'" rel="tag">google-cloud-platform</a> <a href="../../questions/tagged/stream" class="post-tag grid--cell" title="show questions tagged 'stream'" rel="tag">stream</a> <a href="../../questions/tagged/openapi" class="post-tag grid--cell" title="show questions tagged 'openapi'" rel="tag">openapi</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Sep 07 '21 at 20:30">asked Sep 07 '21 at 20:30</time> <a href="../../users/8870397/alexey-gorbel" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/8870397.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="Alexey Gorbel" /> </a> <div class="s-user-card--info"> <a href="../../users/8870397/alexey-gorbel" class="s-user-card--link">Alexey Gorbel</a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">220</li> <li class="s-award-bling s-award-bling__silver" title="3 silver badges">3</li> <li class="s-award-bling s-award-bling__bronze" title="11 bronze badges">11</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="mln24"> <div class="question-summary" id="question-summary-65952381"> <div class="statscontainer"> <div class="stats"> <div class="vote"> <div class="votes"> <span class="vote-count-post"><strong>2</strong></span> <div class="viewcount">votes</div> </div> </div> <div class="status answered-accepted"> <strong>1</strong> answer </div> </div> </div> <div class="summary"> <h3><a href="../../questions/65952381/google-api-gateway-firebase-x-apigateway-api-userinfo-vs-x-forwarded-authoriza" class="question-hyperlink">Google API Gateway + Firebase: X-Apigateway-Api-Userinfo vs X-Forwarded-Authorization headers</a></h3> <div class="excerpt">I'm using Google API Gateway to in my Firebase app to verify if a user is signed-in. In API Gateway's documentation here, it recommends to use the forwarded X-Apigateway-Api-Userinfo header to retrieve user info: API Gateway will send the…</div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/node.js" class="post-tag grid--cell" title="show questions tagged 'node.js'" rel="tag">node.js</a> <a href="../../questions/tagged/firebase" class="post-tag grid--cell" title="show questions tagged 'firebase'" rel="tag">firebase</a> <a href="../../questions/tagged/firebase-authentication" class="post-tag grid--cell" title="show questions tagged 'firebase-authentication'" rel="tag">firebase-authentication</a> <a href="../../questions/tagged/http-headers" class="post-tag grid--cell" title="show questions tagged 'http-headers'" rel="tag">http-headers</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Jan 29 '21 at 10:04">asked Jan 29 '21 at 10:04</time> <a href="../../users/14936201/jason" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/14936201.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="Jason" /> </a> <div class="s-user-card--info"> <a href="../../users/14936201/jason" class="s-user-card--link">Jason</a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">115</li> <li class="s-award-bling s-award-bling__bronze" title="6 bronze badges">6</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="mln24"> <div class="question-summary" id="question-summary-64363526"> <div class="statscontainer"> <div class="stats"> <div class="vote"> <div class="votes"> <span class="vote-count-post"><strong>2</strong></span> <div class="viewcount">votes</div> </div> </div> <div class="status "> <strong>0</strong> answers </div> </div> </div> <div class="summary"> <h3><a href="../../questions/64363526/how-to-create-api-keys-for-securing-google-api-gateway-beta-programmatically" class="question-hyperlink">how to create api keys for securing google API gateway(Beta) programmatically?</a></h3> <div class="excerpt">Use case: Users allowed to create api keys and revoke them from webapp. The docs seem to only show creating Api keys using the Cloud Console. (Link to docs) </div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/google-cloud-platform" class="post-tag grid--cell" title="show questions tagged 'google-cloud-platform'" rel="tag">google-cloud-platform</a> <a href="../../questions/tagged/api-gateway" class="post-tag grid--cell" title="show questions tagged 'api-gateway'" rel="tag">api-gateway</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Oct 15 '20 at 01:16">asked Oct 15 '20 at 01:16</time> <a href="../../users/3818829/jasan" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/3818829.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="jasan" /> </a> <div class="s-user-card--info"> <a href="../../users/3818829/jasan" class="s-user-card--link">jasan</a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">11,475</li> <li class="s-award-bling s-award-bling__gold" title="22 gold badges">22</li> <li class="s-award-bling s-award-bling__silver" title="57 silver badges">57</li> <li class="s-award-bling s-award-bling__bronze" title="97 bronze badges">97</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="mln24"> <div class="question-summary" id="question-summary-76616982"> <div class="statscontainer"> <div class="stats"> <div class="vote"> <div class="votes"> <span class="vote-count-post"><strong>1</strong></span> <div class="viewcount">vote</div> </div> </div> <div class="status "> <strong>1</strong> answer </div> </div> </div> <div class="summary"> <h3><a href="../../questions/76616982/why-is-google-api-gateway-not-passing-my-query-parameter-to-my-cloud-function" class="question-hyperlink">Why is Google api gateway not passing my query parameter to my cloud function?</a></h3> <div class="excerpt">TLDR - moved from one query param (api key) to two in my google api gateway config and it only accepts the first one in the url Seems like this should be easy, but it's not working. I create a google cloud function with some hardcoded params,…</div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/google-cloud-platform" class="post-tag grid--cell" title="show questions tagged 'google-cloud-platform'" rel="tag">google-cloud-platform</a> <a href="../../questions/tagged/google-cloud-functions" class="post-tag grid--cell" title="show questions tagged 'google-cloud-functions'" rel="tag">google-cloud-functions</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Jul 05 '23 at 03:46">asked Jul 05 '23 at 03:46</time> <a href="../../users/752916/alexma" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/752916.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="AlexMA" /> </a> <div class="s-user-card--info"> <a href="../../users/752916/alexma" class="s-user-card--link">AlexMA</a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">9,842</li> <li class="s-award-bling s-award-bling__gold" title="7 gold badges">7</li> <li class="s-award-bling s-award-bling__silver" title="42 silver badges">42</li> <li class="s-award-bling s-award-bling__bronze" title="64 bronze badges">64</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="mln24"> <div class="question-summary" id="question-summary-76424622"> <div class="statscontainer"> <div class="stats"> <div class="vote"> <div class="votes"> <span class="vote-count-post"><strong>1</strong></span> <div class="viewcount">vote</div> </div> </div> <div class="status "> <strong>1</strong> answer </div> </div> </div> <div class="summary"> <h3><a href="../../questions/76424622/cors-error-no-access-control-allow-origin-header-present" class="question-hyperlink">CORS error: No 'Access-Control-Allow-Origin' header present</a></h3> <div class="excerpt">I'm encountering a CORS (Cross-Origin Resource Sharing) issue while making an XMLHttpRequest from my web application. The error message I'm receiving is as follows: Access to XMLHttpRequest at…</div> <div class="grid ai-start jc-space-between fw-wrap"> <div class="grid gs4 fw-wrap tags "> <a href="../../questions/tagged/node.js" class="post-tag grid--cell" title="show questions tagged 'node.js'" rel="tag">node.js</a> <a href="../../questions/tagged/google-cloud-platform" class="post-tag grid--cell" title="show questions tagged 'google-cloud-platform'" rel="tag">google-cloud-platform</a> <a href="../../questions/tagged/cors" class="post-tag grid--cell" title="show questions tagged 'cors'" rel="tag">cors</a> <a href="../../questions/tagged/google-api-gateway" class="post-tag grid--cell" title="show questions tagged 'google-api-gateway'" rel="tag">google-api-gateway</a> </div> <div class="started mt0"> <div class="s-user-card s-user-card"> <time class="s-user-card--time" datetime="asked Jun 07 '23 at 14:55">asked Jun 07 '23 at 14:55</time> <a href="../../users/11804140/muhammad-refda" class="s-avatar s-avatar__32 s-user-card--avatar"> <img class="s-avatar--image" src="../../users/profiles/11804140.webp" data-jdenticon-width="32" data-jdenticon-height="32" data-jdenticon-value="muhammad refda" /> </a> <div class="s-user-card--info"> <a href="../../users/11804140/muhammad-refda" class="s-user-card--link">muhammad refda</a> <ul class="s-user-card--awards"> <li class="s-user-card--rep" title="reputation score">31</li> <li class="s-award-bling s-award-bling__silver" title="1 silver badges">1</li> <li class="s-award-bling s-award-bling__bronze" title="7 bronze badges">7</li> </ul> </div> </div> </div> </div> </div> </div> </div> <div class="s-pagination pager fr"> <div class="s-pagination--item is-selected">1</div> <a class="s-pagination--item" href="../../questions/tagged/google-api-gateway_page=2" rel="" title="Go to page 2">2</a> <a class="s-pagination--item" href="../../questions/tagged/google-api-gateway_page=3" rel="" title="Go to page 3">3</a> <a class="s-pagination--item" href="../../questions/tagged/google-api-gateway_page=4" rel="" title="Go to page 4">4</a> <a class="s-pagination--item" href="../../questions/tagged/google-api-gateway_page=5" rel="" title="Go to page 5">5</a> <a class="s-pagination--item" href="../../questions/tagged/google-api-gateway_page=2" rel="next" title="Go to page 2"> Next</a> </div> </div> </div> </div> </div> <script src="../../static/js/stack-icons.js"></script> <script src="../../static/js/fromnow.js"></script> </body> </html>