Welcome to the Kinde community

Updated 7 months ago

Setting audience in php

At a glance

The community member's post asks how to set the audience in PHP. In the comments, another community member provides an example of how to set the audience when creating a new instance of the `KindeClientSDK` in PHP. The example code shows that the audience parameter needs to be passed as part of the constructor arguments. The community member also mentions that the actual audience value should be replaced in the example code.

how do I set the audience in PHP

K
1 comment

To set the audience in PHP using the Kinde SDK, you need to pass the audience parameter when creating a new instance of the `KindeClientSDK`. Here is an example of how to do this: ``` public function __construct() { $this->kindeClient = new KindeClientSDK( "KINDE_HOST", "KINDE_REDIRECT_URL", "KINDE_CLIENT_ID", "KINDE_CLIENT_SECRET", "KINDE_GRANT_TYPE", "KINDE_POST_LOGOUT_REDIRECT_URL", "YOUR_SCOPES", [ "audience" => "" ] ); } ``` In this example, replace `""` with the actual audience for your API. For more details, you can refer to the .

Add a reply
Sign up and join the conversation on Slack