"Something went wrong" message trying to authorize with Partner Connections Manager - nest-device-access

When I load the Partner Connections Manager authorization URL in the browser, I get the following error message:
Something Went Wrong
What can I do to troubleshoot this?

Make sure that the OAuth Client ID matches between your Device Access project and the Partner Connections Manager (PCM) URL, and that you're using the correct Project ID in the URL.
Go to the Project Info page for your project in the Device Access Console. Note the Project ID and OAuth Client ID assigned to your project. Make sure these values match what you're using in the PCM URL.
For example, if the Project ID for your project is 32c4c3bc-fe0d-461b-b51c-f3885afff2f0 and the OAuth Client ID is 90471209828-u96nolblvuk5jv1b22gdfvov4qgbcbhh.apps.googleusercontent.com, then your PCM URL should look like:
https://nestservices.google.com/partnerconnections/32c4c3bc-fe0d-461b-b51c-f3885afff2f0/auth?
redirect_uri=https://www.google.com&
access_type=offline&
prompt=consent&
client_id=90471209828-u96nolblvuk5jv1b22gdfvov4qgbcbhh.apps.googleusercontent.com&
response_type=code&
scope=https://www.googleapis.com/auth/sdm.service
For more information, see Create a Project and Authorize an Account on the Device Access site.

Related

Account Link Error when Using Device Access Console

I have a Nest Hub Max device and trying to control via API. I have a GCP account with associated OAUTH Client ID and a project ID from the Device Access Console.
I am attempting to link the GCP OAUTH ID and the Device Access Console project but reach screen with message:
"No access to partner - Information could not be retrieved. Please contact NestHubMax to verify that your account has been properly set up. You may need to add the developer email address as a home member in the Google Home app settings."
Have you added your email address to the test users list in the GCP OAuth Consent Screen settings?

How to find my OpenId of Wechat personal account which is following a Wechat Service Account

OpenId is an id of a Wechat personal account when it is following a Wechat Service Account. And the OpenIds are different for the same Wechat personal account in different Wechat Service Accounts.
So I want to find out OpenId of single account only and not the list of all the OpenIds which are following that WeChat service account.
Does anyone know how to get it?
I have to use it to send a message in https://api.weixin.qq.com/cgi-bin/message/template/send
You can get the user info via their UnionID first,(https://developers.weixin.qq.com/doc/offiaccount/en/User_Management/Get_users_basic_information_UnionID.html#UinonId) and then use the OpenID relevant to the current Official Account to send the Templated Message.
This way, your applications just need to track the UnionID, and get the user info on the fly, when needed (can be cached to avoid too many API calls etc).
1.Registing your service account with your email.
2.Getting your appid and appsecret.The appsecret must be saved after gained.
3.Setting the white doname in wechat service account managesites.When you are setting the doname, wechat will make you download a file and put it in your remote server where the doname sets.It will ensure the setting is from you and you can Scan code with your wxchat client.
4.Editing the miniprogram code. Use the method "wx.login()".you can get the jscode in the callback of "wx.login()" send it to your remote server.
5.Editing the remote server code.Send "get" request to get openid with your appid ,appsecret,the jscode from client.
https://api.weixin.qq.com/sns/jscode2session?appid=APPID&secret=SECRET&js_code=JSCODE&grant_type=authorization_code

Wordpress setup, and finding the Authentication Code

I am going over to a Wordpress and my WP plugin is asking me about "Authentication Code" And I have no idea where to find it.
Without the plugin name it is hard for me to determine what specific authentication code is needed, so I'll assume that you mean the OAuth Client ID. Please, forgive me if I am mistaken. You can generate a new OAuth Client ID following this steps:
Open Google Cloud Console and select your project.
Go to Navigation menu ⮞ APIs & Services ⮞ Credentials.
Select +Create credentials ⮞ OAuth client ID at the top.
You'll be prompted to select an application type. In case of a Wordpress plugin you need to choose Web application and give it a descriptive name.
Click on +ADD URI and include your webpage URL. This action will whitelist your webpage to authorize this OAuth client.
Tick Create to finish the process and annotate your client ID and secret.
With this procedure you would have created an OAuth client ID and its secret. Now we can take this client/secret pair and use it to request an authorization code over some Calendar API scopes.
After getting an authorization code, you can ask Google to exchange it for a pair of refresh and access tokens that you can use on every call to the Calendar API.
Following these steps you would have created every authentication code possible, you just need to determine which one is the required for that specific plugin. Please, don't hesitate to ask me any additional doubts.

How do I acquire an OAuth 2.0 Access Token with the r_ads_gen_automation permission for accessing LinkedIn leads for a company page?

My end goal is to register my API to receive notifications of leads generated by LinkedIn for my business's Company Page. The docs here say I need to register at https://api.linkedin.com/v2/leadNotificationUrls using the r_ads_ge_automation permission. I'm trying to acquire this type of access token by using a web browser to hit https://www.linkedin.com/oauth/v2/authorization?response_type=code&client_id=client_id_for_my_application&redirect_uri=https://my.company.net/api/oauth/linkedin&state=Testing12345&scope=r_ads_leadgen_automation, then logging in as a user that is an admin for the respective company page, then acquiring authentication code, and finally requesting an access token.
The problem is that when I try to hit https://www.linkedin.com/oauth/v2/authorization (with the query params above), I get an error response stating "r_ads_leadgen is not authorized for your application". I can't find any kind of application configuration that is supposed to give this permission to my application.
Can anyone help? Thank you
Permissions are offered to select Partners only. Have you applied to a Partner Program https://business.linkedin.com/marketing-solutions/marketing-partners/become-a-partner?

How do enable access to Google Analytics API for an Installed Application?

I am writing a small program to retrieve and display Google Analytics information. I keep getting a 403 Forbidden error because of insufficient permissions.
I read on other posts that you have to add the email address associated with the client id you are using to access analytics in User Management.
The client id I am using however is associated with an installed application and doesn't have an email address, it only lists a client id, client secret, and redirect Urls as credentials in the developer's console.
How can I allow access for this client id when there is no associated email address listed in the developer's console to grant permissions to on the User Management page in Google Analytics?
Simply follow Google's OAuth 2.0 guide for installed applications.
Create a URL for authorization like you would for a web app. Only set redirect_uri to urn:ietf:wg:oauth:2.0:oob.
Point your user to this URL and let him authorize your app. Then the user will receive a code.
Prompt the user to enter this code in your app and use it to retrieve a refresh token from Google.
Store the refresh token and use it to get a fresh access token whenever you need one.

Resources