I've create sub account and tried to get details of my sub account endpoint using plivo api. I following this guide (https://www.plivo.com/docs/getting-started/endpoint-api/#get-details-of-a-single-endpoint)
Request:
GET https://api.plivo.com/v1/Account/{auth_id}/Endpoint/{endpoint_id}/
And the results looks like here:
{
"alias": "sub account1",
"api_id": "cf626892-84bb-11e6-8ede-02ed609bd62b",
"application": "/v1/Account/MAMDIWYJA2M2U3MWNKZJ/Application/20128944308334494/",
"endpoint_id": "14369816564783",
"password": "xxxd95f4feb21412a692e73929961e",
"resource_uri": "/v1/Account/MAMDIWYJA2M2U3MWNKZJ/Endpoint/14369816564783/",
"sip_contact": "sip:xxxxx160923031839@182.253.141.63:44479;transport=TCP;ob",
"sip_expires": "2016-09-29 03:42:33",
"sip_registered": "true",
"sip_uri": "sip:xxxxx160923031839@phone.plivo.com",
"sip_user_agent": "n/a",
"sub_account": "/v1/Account/SAZGE1ZGJLZTE1ZTFMZM/",
"username": "xxxxx160923031839"
}
I still wonder, what is that password field above used for? Is that my endpoint password? Because I can't login using that endpoint username (xxxxx160923031839) and that password (xxxd95f4feb21412a692e73929961e). It was successful only when I tried to login using that endpoint username (xxxxx160923031839) and my main account password.
FYI: I am using android plivo sample project
Anyone know? Thanks.
Plivo Sales Engineer here.
The password that you see in the response is the encrypted version of the actual password that was set while creating the endpoint. You should use the actual password of the endpoint to login to your android app. Your main account password is different from your endpoint password.