I want to validate the App ID , e.g. sd108 from user entry. I don’t see a way to do that in the V2 API.
How to retrieve the App ID given a Service Acct. Key?
Thanks
I want to validate the App ID , e.g. sd108 from user entry. I don’t see a way to do that in the V2 API.
How to retrieve the App ID given a Service Acct. Key?
Thanks
@Jeffrey_Chimene I don’t believe there’s an endpoint to do that (maybe someone from Keap can weigh in), but if you’re using OAuth you will receive the app id as part of the scope GET parameter when a user completes the OAuth flow.
The return url gets query params that look something like this: ?code=ABCDEF1234567&scope=full|abc123.infusionsoft.com
I understand this may not be suitable for your scenario….maybe? ![]()
Hi @Jeffrey_Chimene currently this isn’t possible via our REST APIs, as there’s no endpoint to retrieve or validate an App ID. Could you let me know your use case?
@Todd_Stoker I’m not using OAuth, using SAK technique
@OmarAlmonte Use case is to workaround this issue. The V1 endpoint requires the app id. This endoint would be used to test user input
@Jeffrey_Chimene the issue is in the SDK, the endpoint itself is working as expected and can still be called directly without the SDK.
We’ve identified the problem in the SDK mapping. As a workaround, you can fix it locally by updating the following file:
GetApplicationEnabledStatusResponse.php
Change the attribute mapping from:
protected static $attributeMap = [
'enabled' => 'enabled'
];
to
protected static $attributeMap = [
'enabled' => 'isEnabled'
];
Thanks @OmarAlmonte , I will try that.
I’d still like to validate the App Id when using a Service Account Key. A correct value will be needed for the Achieve. API goal call in V1.
I guess it’s not a solution to this thread.
@Jeffrey_Chimene I’ll raise this internally and follow up with an update.
Hi @Jeffrey_Chimene @Todd_Stoker @Pav @Timothy_Withers, tenant_id(App ID) is now returned in the GET /v2/oauth/connect/userinfo endpoint.
I’m using SAK
@Jeffrey_Chimene the endpoint also works if you authenticate using PATs or SAKs.
@OmarAlmonte
It looks like this is still an issue.
Hi Jeffrey, this should be resolved.
You can verify it with the following curl:
curl --request GET \
--url "https://api.infusionsoft.com/oauth/connect/userinfo" \
--header "Authorization: Bearer YOUR_ACCESS_TOKEN"
This endpoint returns the tenant_id property, which corresponds to the app, and it works with SAKs as well.
If you’re still seeing issues, could you share the request you’re sending and the response you’re getting? Happy to take a closer look.
@OmarAlmonte
I’m not seeing issues w/ that call, since I’m not using that call.
I’m using the IsApplicationEnabled call, which is in the Settings API. The model used in that call does not reflect the change you posted earlier.
Thanks for the clarification. The SDK issue is already in progress; I’ve just added it to the tracker (Item #85) so you can track it there. I’ll let you know as soon as it’s released.
Hi @Jeffrey_Chimene.
Thanks again for reporting this issue. We’ve fixed the attribute mapping bug in the SDK, and it’s now resolved in version 2.0.6 .
Please update to the latest version and let us know if you run into anything else.
We really appreciate your help in catching this!