Comments (3)
Hi, the Root resource is already created by API gateway, I'm honestly not
sure it it's possible to manipulate but it would require a separate
resource type to do so.
What you can do is create a regular http method of type OPTIONS on the root
resource but then you have to make sure you add the allow-origin header on
the other methods on the root resource. Tedious....
I'll give this some thought and see what I come up with, enabling Cora on
the root resource makes perfect sense so it sh be supported :)
On mån 18 apr. 2016 at 15:44, Richard Hurt [email protected] wrote:
I'm trying to add CORS support to the root "/" resource. However, the
ApiResource requires a pathPart but doesn't accept a null "" or root "/"
string. Is there a way to create CORS options without specifying a pathPart
or is there a magic "null" pathPart that will create things at the root
resource?—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#40
from aws-api-gateway-for-cloudformation.
Yes, that makes sense. I think creating the OPTIONS method on root might work. I'll give it a shot. :)
from aws-api-gateway-for-cloudformation.
From version 1.6.0 you can specify CORS config on the rest api, this config will be applied to the parent resource of the API. It works exactly the same way as CORS configuration on Custom::APIResource.
https://apigatewaycloudformation.bynordenfelt.com/#custom-RestApi
from aws-api-gateway-for-cloudformation.
Related Issues (20)
- no build script so can't build a fork to try it out HOT 3
- Errors during create of stack: NoSuchBucket HOT 4
- Add Type to documentation HOT 1
- Allow CORS method wildcard
- runtime error when using IAM certificate HOT 5
- So, how do I actually use this to deploy my api? HOT 4
- Error on creating Custom::ApiMethod: "Response object is too long." HOT 9
- Using Swagger/OpenAPI definitions HOT 2
- Complex api deployment fails due to api gateway throttling HOT 3
- Not possible to create multiple integration responses for one status code
- no git tags/github releases, no love HOT 1
- Allow built-in input-passthrough on methods HOT 1
- May I ask why use "Custom::RestApi"? HOT 2
- v2.0.0 - New supported region Sydney should be "ap-southeast-2" instead of "ap-northeast-2" which is Seoul HOT 2
- Unable to import YAML Swagger definitions using "Custom::ApiImport" property "apiDefinition" HOT 2
- Certificate Chain error when creating custom domain name HOT 4
- Export ServiceToken for cross-stack references HOT 6
- ApiDeploy fails with NetworkingError: write EPROTO HOT 1
- Can you clarify the problems with updating from nodejs to nodejs4.3? HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aws-api-gateway-for-cloudformation.