Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generated API Gateway SDK does not provide a way to pass http headers #2124

Open
mdkv4 opened this issue Sep 23, 2019 · 5 comments
Open

Generated API Gateway SDK does not provide a way to pass http headers #2124

mdkv4 opened this issue Sep 23, 2019 · 5 comments
Labels
feature-request A feature should be added or improved. p3 This is a minor priority issue

Comments

@mdkv4
Copy link

mdkv4 commented Sep 23, 2019

Consider an API Gateway endpoint with a required HTTP request header for Accept-Language (e.g OpenAPI def):

  "paths": {
    "/jobs/{id}": {
      "get": {
        "operationId": "getById",
        "produces": [
          "application/json"
        ],
        "parameters": [
          {
            "name": "Accept-Language",
            "in": "header",
            "required": true,
            "type": "string"
          }

The generated Ruby SDK does not provide a way to pass the required parameter to the endpoint.

Gem name ('aws-sdk', 'aws-sdk-resources' or service gems like 'aws-sdk-s3') and its version

API Gateway generated aws-sdk-v3

Thanks,

@cjyclaire cjyclaire added the feature-request A feature should be added or improved. label Sep 23, 2019
@cjyclaire
Copy link
Contributor

Thanks for the feedback! Tracking this as a feature request for our client interface : D

@github-actions
Copy link

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Sep 23, 2020
@mullermp mullermp removed the closing-soon This issue will automatically close in 4 days unless further comments are made. label Sep 23, 2020
@matjamesymj
Copy link

matjamesymj commented Nov 7, 2020

I have been trying to get headers to show up in the generated gem but they only seem to work if you prefix with an X. So 'X-MY-header-example' works but, 'MY-header-example' does not work. We need the latter to work. Does anyone know how to achieve this?

Example serverless file:

events:
  - http:
      path: /v1/my-test-endpoint
      method: POST
      documentation:
        summary: 'test summary'
        description: 'test desc'
        requestModels:
          application/json: TestRequest
        requestHeaders:
          - name: MY-header-example
            description: 'example header that does not work'
            required: true
          - name: X-MY-header-example
            description: 'example header that works'
            required: true
          - name: X-Correlation-ID
            description: '	Unique ID that can be used to tie together log and other messages across multiple systems.'
            required: true
        methodResponses:
          - statusCode: '200'
            responseBody:
              description: 'Response for example endpoint'
            responseModels:
              application/json: EmptyResponse
          - statusCode: '400'
            responseModels:
              application/json: ExampleErrors
          - statusCode: '500'
            responseModels:
              application/json: ExampleErrors
      reqValidatorName: RequestValidator
      authorizer: aws_iam

@github-actions
Copy link

github-actions bot commented Nov 8, 2021

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Nov 8, 2021
@mullermp mullermp removed the closing-soon This issue will automatically close in 4 days unless further comments are made. label Nov 8, 2021
@github-actions
Copy link

github-actions bot commented Nov 9, 2022

Greetings! We’re closing this issue because it has been open a long time and hasn’t been updated in a while and may not be getting the attention it deserves. We encourage you to check if this is still an issue in the latest release and if you find that this is still a problem, please feel free to comment or open a new issue.

@github-actions github-actions bot added the closing-soon This issue will automatically close in 4 days unless further comments are made. label Nov 9, 2022
@mullermp mullermp removed the closing-soon This issue will automatically close in 4 days unless further comments are made. label Nov 9, 2022
@bhavya2109sharma bhavya2109sharma added the p3 This is a minor priority issue label Jul 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A feature should be added or improved. p3 This is a minor priority issue
Projects
None yet
Development

No branches or pull requests

5 participants