melodic-oil-50942
05/02/2024, 2:08 PMchilly-king-10285
05/02/2024, 2:08 PMchilly-king-10285
05/02/2024, 2:08 PMclient_id for OAuth2 can be obtained when you create an OAuth2 client using the Ory CLI. Here is an example command to create an OAuth2 client: bash ory create oauth2-client --project "$project_id" \ --name "Ory Docs OAuth2 Integration Example Client" \ --grant-type authorization_code,refresh_token,client_credentials \ --response-type code \ --scope openid --scope offline_access --scope email \ --redirect-uri <http://localhost:3000/callback> After running this command, you will receive an output that includes the client_id. You can then set this client_id as an environment variable: bash export OAUTH_CLIENT_ID="{set to the client ID from output}" You can also retrieve the details of an existing OAuth2 client, including its client_id, using the get command: bash ory get oauth2-client <id-1> [<id-2> ...] [flags] Please replace <id-1> with the ID of your OAuth2 client. For more details, please refer to the [Ory documentation](https://www.ory.sh/docs/getting-started/oauth2-openid/add-oauth2-openid-connect-nodejs-expressjs#prerequisites).melodic-oil-50942
05/02/2024, 2:08 PMsparse-father-97864
05/02/2024, 4:21 PMmelodic-oil-50942
05/02/2024, 4:46 PM