My Business
3.6K members online now
3.6K members online now
For developers who are using the Google My Business API to manage locations
Guide Me
star_border
Reply

.Net Integration

[ Edited ]
Visitor ✭ ✭ ✭
# 1
Visitor ✭ ✭ ✭

Hi - 

 

I am integrating GMB in my solution to push my location data into GMB. I am writing code in c# which will pull locations data from my database and will post same into GMB.

 

Can you please advise the steps which I should take. Working code sample should be appreciated.

 

I have API key for my business.

 

Regards

M

1 Expert replyverified_user

Re: .Net Integration

Google Employee
# 2
Google Employee

Hi @Manvendra P,

 

API Key authentication is not supported by the Google My Business API. The Google My Business API accesses protected (non-public) data, therefore you will need an OAuth 2.0 client ID for letting your application request authorization to access your organization's location data on behalf of your app's users. Please follow instructions on the Prerequisites page of the Google Developers site to get started with the Google My Business API.

 

The C# client library doesn’t currently support the display of detailed error messages. Please follow the Make a simple HTTP request step on the Get Started page of the documentation website to learn how to use the OAuth 2.0 Playground for troubleshooting errors with detailed error messages when sending requests with data via the Google My Business API.

 

There are plenty of resources for using the C# client library on this forum. When you search in the Google My Business API community for the answer, please use the search box at the top of the page and filter your search results “By location” and select the “Google My Business API” board. This will limit your search results to the topics created in the Google My Business API board only. You can click on “Advanced Search…” to the right of the search box on the search results page to view results by “Specific posts” for the answer found in posts under a topic.

 

I’ve previously answered your question about setting up the C# client library in this thread.

 

You can learn about how to use an OAuth 2.0 client ID or a service account with the C# client library in this thread.

 

You can learn about listing locations and including the pageSize and pageToken query parameters with the C# client library in this thread.

 

You can learn about sending a POST request to create a new location with the C# client library in this thread.

 

You can learn about sending a PATCH request to update the specified location with the C# client library in this thread.

 

Thanks,

Terry