Add Home Member

Last Updated on : 2023-06-20 15:35:27download

Add members to a specified home.

API address

POST: /v1.0/homes/{home_id}/members

Request parameter

Parameter nameTypeINRequiredDescription
home_idLonguritrueThe ID of a home.

Description of body

Parameter nameTypeINRequiredDescription
app_schemaStringbodytrueThe account schema.
memberObjectbodytrueThe member's object.

Description of member

Parameter nameTypeINRequiredDescription
country_codeStringbodytrueThe country code.
member_accountStringbodytrueThe member's account.
adminBooleanbodytrueSpecifies whether the user is an administrator.
nameStringbodytrueThe member's name.

Return parameter

Parameter nameTypeDescription
resultBooleantrue is returned when the operation is successful.

Request example

POST: /v1.0/homes/2422120/members
{
  "app_schema": "test",
  "member": {
    "country_code": "86",
    "member_account": "1565815****",
    "admin": false,
    "name": "James"
  }
}

Return example

{
    "result": true,
    "t": 1540799657137,
    "success": true
}

Error code

For more information, see error code.