<@U04UQ68083H> How can we implement authorization ...
# ory-copilot
s
@chilly-king-10285 How can we implement authorization code flow of hydra without UI or any user to grant consent.
c
A message from kapa.ai
In Ory Hydra, it's not possible to completely omit the consent redirection flow. However, you can accept the redirection to the redirect URL immediately. This process is so quick (less than 100ms) that the user won't notice it. To implement this, you can follow the example provided in the Hydra documentation on how to skip the consent screen. This will provide a good starting point for your implementation. Please note that this approach doesn't completely eliminate the consent flow, but it does make it invisible to the user. For more details, you can refer to the [Hydra FAQ](https://www.ory.sh/docs/hydra/faq#how-to-omit-consent-redirection) and the guide on [Skipping Consent Screen](https://www.ory.sh/hydra/docs/guides/consent/#skipping-consent-screen).
s
@chilly-king-10285 Can we get refresh token in client credentials flow of ory hydra
c
A message from kapa.ai
No, you cannot obtain a refresh token in the client credentials flow of Ory Hydra. The client credentials flow does not support refresh tokens. This is because the client credentials flow is designed for server-to-server communication and does not involve a user, hence there is no need for a refresh token. For more details, you can refer to the [Requirements for obtaining a refresh token](https://www.ory.sh/docs/oauth2-oidc/refresh-token-grant#requirements-for-obtaining-a-refresh-token) section in the Ory documentation.