My Business Q&A API
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
借助 My Business Q&A API,可以针对特定商家信息发布问题和回答。
注意:如果您在启用该 API 后的配额为 0,请申请 GBP API 访问权限。
服务:mybusinessqanda.googleapis.com
要调用此服务,我们建议您使用 Google 提供的客户端库。如果您的应用程序需要使用自己的库来调用此服务,请在发出 API 请求时使用以下信息。
发现文档
发现文档是用于说明和使用 REST API 的机器可读规范。它用于构建客户端库、IDE 插件以及与 Google API 交互的其他工具。一项服务可能会提供多个发现文档。此服务提供了以下发现文档:
服务端点
服务端点是指定 API 服务的网络地址的基本网址。一项服务可能有多个服务端点。此服务具有以下服务端点,下面的所有 URI 都与此服务端点相关:
https://mybusinessqanda.googleapis.com
方法 |
create |
POST /v1/{parent=locations/*/questions}
针对指定位置添加问题。 |
delete |
DELETE /v1/{name=locations/*/questions/*}
删除当前用户撰写的特定问题。 |
list |
GET /v1/{parent=locations/*/questions}
返回指定位置的分页问题列表及其部分答案。 |
patch |
PATCH /v1/{question.name=locations/*/questions/*}
更新当前用户撰写的特定问题。 |
方法 |
delete |
DELETE /v1/{name=locations/*/questions/*}/answers:delete
删除当前用户为题目撰写的回答。 |
list |
GET /v1/{parent=locations/*/questions/*}/answers
返回指定问题的分页答案列表。 |
upsert |
POST /v1/{parent=locations/*/questions/*}/answers:upsert
针对指定问题创建答案或更新用户撰写的现有答案。 |
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-25。
[null,null,["最后更新时间 (UTC):2025-07-25。"],[[["\u003cp\u003eThe My Business Q&A API enables posting questions and answers for specific business listings.\u003c/p\u003e\n"],["\u003cp\u003eYou can manage questions and answers programmatically using the API's REST resources.\u003c/p\u003e\n"],["\u003cp\u003eThe API provides methods to create, delete, list, and update questions and answers.\u003c/p\u003e\n"],["\u003cp\u003eTo use this API, you will need to enable it and may require requesting access through Google.\u003c/p\u003e\n"]]],[],null,["# My Business Q&A API\n\nThe My Business Q\\&A API allows questions and answers to be posted for specific listings. \n\nNote - If you have a quota of 0 after enabling the API, please [request](https://developers.google.com/my-business/content/prereqs#request-access) for GBP API access.\n\n- [REST Resource: v1.locations.questions](#v1.locations.questions)\n- [REST Resource: v1.locations.questions.answers](#v1.locations.questions.answers)\n\nService: mybusinessqanda.googleapis.com\n---------------------------------------\n\nTo call this service, we recommend that you use the Google-provided [client libraries](https://cloud.google.com/apis/docs/client-libraries-explained). If your application needs to use your own libraries to call this service, use the following information when you make the API requests.\n\n### Discovery document\n\nA [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) is a machine-readable specification for describing and consuming REST APIs. It is used to build client libraries, IDE plugins, and other tools that interact with Google APIs. One service may provide multiple discovery documents. This service provides the following discovery document:\n\n- \u003chttps://mybusinessqanda.googleapis.com/$discovery/rest?version=v1\u003e\n\n### Service endpoint\n\nA [service endpoint](https://cloud.google.com/apis/design/glossary#api_service_endpoint) is a base URL that specifies the network address of an API service. One service might have multiple service endpoints. This service has the following service endpoint and all URIs below are relative to this service endpoint:\n\n- `https://mybusinessqanda.googleapis.com`\n\nREST Resource: [v1.locations.questions](/my-business/reference/qanda/rest/v1/locations.questions)\n-------------------------------------------------------------------------------------------------\n\n| Methods ||\n|---------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------|\n| [create](/my-business/reference/qanda/rest/v1/locations.questions/create) | `POST /v1/{parent=locations/*/questions}` Adds a question for the specified location. |\n| [delete](/my-business/reference/qanda/rest/v1/locations.questions/delete) | `DELETE /v1/{name=locations/*/questions/*}` Deletes a specific question written by the current user. |\n| [list](/my-business/reference/qanda/rest/v1/locations.questions/list) | `GET /v1/{parent=locations/*/questions}` Returns the paginated list of questions and some of its answers for a specified location. |\n| [patch](/my-business/reference/qanda/rest/v1/locations.questions/patch) | `PATCH /v1/{question.name=locations/*/questions/*}` Updates a specific question written by the current user. |\n\nREST Resource: [v1.locations.questions.answers](/my-business/reference/qanda/rest/v1/locations.questions.answers)\n-----------------------------------------------------------------------------------------------------------------\n\n| Methods ||\n|-----------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [delete](/my-business/reference/qanda/rest/v1/locations.questions.answers/delete) | `DELETE /v1/{name=locations/*/questions/*}/answers:delete` Deletes the answer written by the current user to a question. |\n| [list](/my-business/reference/qanda/rest/v1/locations.questions.answers/list) | `GET /v1/{parent=locations/*/questions/*}/answers` Returns the paginated list of answers for a specified question. |\n| [upsert](/my-business/reference/qanda/rest/v1/locations.questions.answers/upsert) | `POST /v1/{parent=locations/*/questions/*}/answers:upsert` Creates an answer or updates the existing answer written by the user for the specified question. |"]]