Search code examples
huawei-mobile-serviceshuawei-developersappgalleryappgallery-connect

HMS: Unable to reply to comment through API


Trying to reply to a customer comment using the API.

Calling the reply to comment API The reply gets submitted and returns rtnCode for success

Getting

{ ret: { rtnCode: 50010003, rtnDesc: 'param error' } }

The API details that we use when we submit in HTTP format is as follows

POST /api/reviews/v1/manage/dev/reviews HTTP/1.1

Host: connect-api-dra.cloud.huawei.com

requestId: XXXXXXXXXXXXXXXXXX

client_id: XXXXXXXXXXXXXXXXXX

Authorization: Bearer {Access token here}

Content-Type: application/json

Content-Length: 414

    {
    
        "lang": "en-US",
    
        "appId": "XXXXXXXX",
    
        "reviewId": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
    
        "devReplyContent": "Dear, Thank you for your Wonderful feedback. We appreciate your feedback and star rating. Please feel free to reach out to us anytime if you have any questions!",
    
        "countryCode": "IN"
    
    }

Solution

  • According to this docs : Language, for example, zh_CN. The value consists of a language code defined in ISO-639-2 and a country/region code, separated with an underscore (_).

    enter image description here

    So you could try to change the short line here to underscore and see if it works.

    enter image description here