<@U04UQ68083H> ory patch project deb1d954-1bc5-40...
# ory-copilot
a
@chilly-king-10285 ory patch project deb1d954-1bc5-40a0-a2b2-ec5f08060cb2 --replace '/cors_public/enabled=true' --replace '/cors_public/origins=["https://*.foobar.ory"]' value for /cors_public/origins must be valid JSON but got: [https://*.foobar.ory]
c
A message from kapa.ai
It seems like you're trying to enable CORS for your Ory project using the Ory CLI. However, the error message suggests that the JSON value you're providing for the
origins
field is not valid. In the command you've provided, you're trying to set the
origins
field with the value
["https://*.foobar.ory"]
. However, based on the information provided in the extracts, the correct field name should be
allowed_origins
instead of
origins
. Here's the corrected command:
Copy code
bash ory patch project deb1d954-1bc5-40a0-a2b2-ec5f08060cb2 --replace '/cors_public/enabled=true' --replace '/cors_public/allowed_origins=["https://*.foobar.ory"]'
This command will enable CORS for your project and allow requests from any subdomain of
foobar.ory
. For more information about the
ory patch
command, you can refer to the [Ory CLI documentation](https://www.ory.sh/docs/guides/cli/config-with-cli#patch-configuration).