early-oil-83208
11/13/2023, 12:29 PM$ ory patch oauth2-config $PROJECT \
--add '/oauth2/token_hook/url="<https://my-example.app/token-hook>"' \
--format yaml
I[#/oauth2/token_hook] S[#/properties/oauth2/properties/token_hook/oneOf] oneOf failed
I[#/oauth2/token_hook] S[#/properties/oauth2/properties/token_hook/oneOf/0/type] expected string, but got object
I[#/oauth2/token_hook] S[#/properties/oauth2/properties/token_hook/oneOf/1/$ref] doesn't validate with "#/definitions/webhook_config"
I[#/oauth2/token_hook/auth] S[#/definitions/webhook_config/properties/auth] validation failed
I[#/oauth2/token_hook/auth/config/in] S[#/definitions/webhook_config/properties/auth/properties/config/properties/in/enum] value must be one of "header", "cookie"
I[#/oauth2/token_hook/auth/type] S[#/definitions/webhook_config/properties/auth/properties/type/const] value must be "api_key"
proud-plumber-24205
11/13/2023, 12:36 PMconfig
path.
ory patch oauth2-config $PROJECT \
--add '/oauth2/config/token_hook/url="<https://my-example.app/token-hook>"' \
--format yaml
proud-plumber-24205
11/13/2023, 12:37 PMearly-oil-83208
11/13/2023, 12:52 PMory get oauth2-config...
or via the UI
Is there a way to see this configuration change?proud-plumber-24205
11/13/2023, 12:52 PMproud-plumber-24205
11/13/2023, 2:23 PMory patch oauth2-config $PROJECT \
--add '/oauth2/token_hook={"url":"<https://example.com>", "auth": {"type":"api_key", "config":{"api_key_name":"","api_key_value":"", "in":"header"}}}'
--format yaml
proud-plumber-24205
11/13/2023, 2:24 PM/oauth2/token_hook/url
path is not supported at the moment due to the bug. I'll create a bug report for this, sorry for the inconvenience 🙏proud-plumber-24205
11/13/2023, 2:28 PMearly-oil-83208
11/13/2023, 2:28 PMproud-plumber-24205
11/13/2023, 2:33 PMearly-oil-83208
11/13/2023, 4:11 PMoauth2-config
via the cli.
The URL doesn't actually seem to be called though.
Any way to verify it, or something I should look out for to troubleshoot?proud-plumber-24205
11/13/2023, 5:10 PM/oauth2/token
endpoint. I would need to check, maybe the config workaround is causing some other issues.proud-plumber-24205
11/13/2023, 5:11 PMproud-plumber-24205
11/15/2023, 4:57 PMearly-oil-83208
11/15/2023, 5:21 PMnarrow-van-43826
11/16/2023, 12:53 PMory patch oauth2-config $PROJECT \
--add '/oauth2/token_hook="<https://my-example.app/token-hook>"' \
--format yaml
should do it. Let me know if that works.early-oil-83208
11/16/2023, 4:10 PMory patch oauth2-config $PROJECT --remove '/oauth2/token_hook' --format yaml
and set again with your command, then narrow-van-43826
11/17/2023, 6:59 AMnarrow-van-43826
11/20/2023, 8:36 AMory patch oauth2-config 9b69f5f5-8cc9-4fec-ae6d-0f77fed207ea --add '/oauth2/token_hook="<https://my-example.app/token-hook>"'
will work without passing any credentials. If you need to pass credentials, you still can with this format: https://www.ory.sh/docs/hydra/guides/claims-at-refresh#webhook-authenticationnarrow-van-43826
11/20/2023, 5:18 PMearly-oil-83208
11/21/2023, 9:13 AM