POST/api/v4/locations/reviews/respond

상호작용에 답글 작성하기

리뷰 또는 상호작용이 발생한 플랫폼에 공개 답글을 게시합니다.

API 키가 필요합니다. 헤더 형식과 키 교체는 인증을 참고하세요.

매개변수

본문

이름유형필수설명
interactionIdstring필수UUID of the interaction to respond to. Take it from an interaction's `id` or `interactionId`, which are the same value. It is a plain UUID, with no numeric or Base64 Relay form.
responseContentstring필수Text content of the response to post.
respondedWithstring선택Response-template ID to attribute the reply to, if it was generated from a template.

요청 예시

바로 붙여 넣을 수 있는 본문입니다. 예시 ID와 값을 실제 값으로 바꾸세요.

Request body
{  "interactionId": "9e26d2a8-a6ed-42ea-8454-47d1c92ea841",  "responseContent": "Thank you for visiting Jenny Home: we're glad you enjoyed your experience!"}

응답

200Response accepted and queued for posting. `data.respondToInteraction.interaction` holds the created response.
Response
{  "data": {    "respondToInteraction": {      "interaction": {        "id": "2090753a-ece6-4837-8336-8494ad308523",        "interactionId": "9e26d2a8-a6ed-42ea-8454-47d1c92ea841",        "content": "Thank you for visiting Jenny Home: we're glad you enjoyed your experience!",        "interactionStatus": "CREATED",        "editedResponse": false      },      "errors": null    }  }}
401Unauthenticated, missing or invalid API key.

일반적인 오류

  • SY50121: Google Reviews accept only a single owner reply per review; a second response is rejected.

리뷰 또는 상호작용이 발생한 플랫폼(예: Google, Facebook)에 답글을 게시합니다. 답글은 비동기적으로 제출됩니다. interactionStatus는 즉시 CREATED가 되며, 플랫폼에서 이를 확인하면 COMPLETED 또는 CONFIRMED로 전환됩니다(또는 FAILED로 전환됩니다. 답글 상태 흐름을 참조하세요).

모든 플랫폼이 소유자 답글을 지원하는 것은 아닙니다. 호출하기 전에 상호작용 객체의 canRespond를 확인하세요. Google 리뷰는 리뷰당 답글을 1개만 허용합니다(다시 시도하면 SY50121이 반환됩니다). 기존 답글을 변경하려면 새 답글을 게시하는 대신 답글 수정을 사용하세요.

사용 사례: 새로운 별점 5점 리뷰에 자동으로 답글 달기

만족한 리뷰 작성자에게 자동으로 감사를 표하려면 ratingFilters=[5]와 responseStatus=["PENDING"]을 사용하여 상호작용 목록 조회를 폴링한 다음, 반환된 node 중 canRespond가 true인 각 항목에 대해 해당 항목의 id를 interactionId로 지정하고 responseContent를 포함하여 POST 요청을 보냅니다.

JSON
{  "interactionId": "9e26d2a8-a6ed-42ea-8454-47d1c92ea841",  "responseContent": "Thank you for visiting Jenny Home: we're glad you enjoyed your experience!"}

게시는 비동기적으로 처리되므로 200만으로 성공했다고 가정하지 말고, ID로 상호작용 조회를 통해 상호작용을 다시 가져와 답글이 COMPLETED/CONFIRMED 상태에 도달했는지 확인하세요.

Request
curl -X POST 'https://listingsapi.com/api/v4/locations/reviews/respond' \  -H "Authorization: API $LISTINGSAPI_KEY" \  -H 'Content-Type: application/json' \  -d '{    "interactionId": "9e26d2a8-a6ed-42ea-8454-47d1c92ea841",    "responseContent": "Thank you for visiting Jenny Home: we're glad you enjoyed your experience!"  }'