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

Update/Refresh API gateway bodyS3Location #4421

Closed
2 tasks
cheelav opened this issue Oct 8, 2019 · 4 comments · Fixed by #7372
Closed
2 tasks

Update/Refresh API gateway bodyS3Location #4421

cheelav opened this issue Oct 8, 2019 · 4 comments · Fixed by #7372
Assignees
Labels
@aws-cdk/aws-apigateway Related to Amazon API Gateway effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. in-progress This issue is being actively worked on.

Comments

@cheelav
Copy link

cheelav commented Oct 8, 2019

I have created API gateway and importing swagger doc with bodyS3Location property. Not able to refresh gateway after uploading new swagger docs.

Use Case

Proposed Solution

Other

  • 👋 I may be able to implement this feature request
  • ⚠️ This feature might incur a breaking change

This is a 🚀 Feature Request

@cheelav cheelav added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Oct 8, 2019
@NGL321 NGL321 removed feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Oct 8, 2019
@NGL321
Copy link
Contributor

NGL321 commented Oct 8, 2019

Hi @cheelav,

I'm not really sure what you are asking. If you would like to request a feature, please describe the feature you want, why you want it, and how you think it could be implemented.

It really looks like you are trying to figure out how a system works. My recommendation is to look at our Gitter room or StackOverflow. However, if you would like to get an answer here, please provide more information on your issue.

@NGL321 NGL321 self-assigned this Oct 8, 2019
@NGL321 NGL321 added closing-soon This issue will automatically close in 4 days unless further comments are made. guidance Question that needs advice or information. pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. labels Oct 8, 2019
@cheelav
Copy link
Author

cheelav commented Oct 9, 2019 via email

@NGL321
Copy link
Contributor

NGL321 commented Oct 15, 2019

Hey @cheelav were you going to post some ts? I can certainly look into this more, but I would need to see some code to really understand what you mean

@NGL321 NGL321 added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. and removed closing-soon This issue will automatically close in 4 days unless further comments are made. labels Oct 15, 2019
@cheelav
Copy link
Author

cheelav commented Oct 15, 2019

import cdk = require('@aws-cdk/core');
import apigw = require('@aws-cdk/aws-apigateway');
import { EndpointType } from '@aws-cdk/aws-apigateway';
import iam = require('@aws-cdk/aws-iam');
import { PolicyStatement, PolicyDocument } from '@aws-cdk/aws-iam';

export class ApiCdkStack extends cdk.Stack {
  constructor(scope: cdk.Construct, id: string, props?: cdk.StackProps) {
    super(scope, id, props);



    const api = new apigw.RestApi(this, 'AuthApi', {
      restApiName: 'AuthApi',
      endpointTypes: [EndpointType.REGIONAL],
      parameters: {
        endpointConfigurationTypes: EndpointType.REGIONAL
      }
    });

    api.root.addMethod('ANY');
    //const cfnApi = api.node.findChild('Default') as apigw.CfnRestApi;
    const cfnApi = api.node.defaultChild as apigw.CfnRestApi;

 
    cfnApi.parameters = {
      endpointConfigurationTypes: EndpointType.REGIONAL,
      ignore: 'documentation'
    }

    cfnApi.endpointConfiguration = {
      types: [EndpointType.REGIONAL]
    };

    cfnApi.bodyS3Location = {
      bucket: 'swagger-bucket',
      key: 'Test-AWS-APIGateway.postman_collection.json-Swagger'
    }

  }
}

@NGL321 NGL321 removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 7 days. label Oct 17, 2019
@SomayaB SomayaB removed the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Jan 30, 2020
@SomayaB SomayaB added in-progress This issue is being actively worked on. @aws-cdk/aws-apigateway Related to Amazon API Gateway labels Apr 16, 2020
@SomayaB SomayaB added feature-request A feature should be added or improved. and removed guidance Question that needs advice or information. labels Apr 16, 2020
@nija-at nija-at added the effort/medium Medium work item – several days of effort label Apr 22, 2020
@mergify mergify bot closed this as completed in #7372 May 11, 2020
mergify bot pushed a commit that referenced this issue May 11, 2020
Co-authored-by: Niranjan Jayakar <nija@amazon.com>

Ability to import an OpenAPI definition to an API Gateway Rest API.
The definition can either be a file as a local asset, inline JSON or a
key in an S3 bucket.

closes #4421
karupanerura pushed a commit to karupanerura/aws-cdk that referenced this issue May 22, 2020
Co-authored-by: Niranjan Jayakar <nija@amazon.com>

Ability to import an OpenAPI definition to an API Gateway Rest API.
The definition can either be a file as a local asset, inline JSON or a
key in an S3 bucket.

closes aws#4421
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
@aws-cdk/aws-apigateway Related to Amazon API Gateway effort/medium Medium work item – several days of effort feature-request A feature should be added or improved. in-progress This issue is being actively worked on.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants