Create a home

POST/homes

Base URL: https://api.tinkermode.com

Create a home. If the request is made by a user, the user will be automatically added as a member of the home.

If the request is made using the API key of a user who has permission to create homes, or a project API key with "Admin" privileges, the home will be created without any member. (Members must be explicitly added later.)

In either cases, the request body must contain the "name" field.

Authentication

Send an Authorization header of the form ModeCloud <AUTH_CODE>.

Must contain a user, service account, or project API key.

Request body

Content type: application/json

PropertyTypeRequiredConstraintsDescription
creationTimestringNoread-only (server-generated); format: date-timeTimestamp of home creation.
deactivatedbooleanNoTrue if home has been deactivated by project admin.
idintegerYesread-only (server-generated)Unique ID assigned at time of creation.
namestringYesDisplay name of home.
projectIdintegerYesread-only (server-generated)Project that this home belongs to.
tenantobjectNoTenant information associated with a home.
Properties of tenant
PropertyTypeRequiredConstraintsDescription
agencyAdminAccessControlGroupIdintegerYesread-only (server-generated)ID of the access control group that serves as the agency admin for this tenant.
identifierstringYesread-only (server-generated)Unique identifier for the tenant within the project.
tenantAdminAccessControlGroupIdintegerYesread-only (server-generated)ID of the access control group that serves as the tenant admin for this tenant.

Request example

{
  "name": "Home_Base"
}

Responses

201 Successfully created a new home.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
creationTimestringNoread-only (server-generated); format: date-timeTimestamp of home creation.
deactivatedbooleanNoTrue if home has been deactivated by project admin.
idintegerYesread-only (server-generated)Unique ID assigned at time of creation.
namestringYesDisplay name of home.
projectIdintegerYesread-only (server-generated)Project that this home belongs to.
tenantobjectNoTenant information associated with a home.
Properties of tenant
PropertyTypeRequiredConstraintsDescription
agencyAdminAccessControlGroupIdintegerYesread-only (server-generated)ID of the access control group that serves as the agency admin for this tenant.
identifierstringYesread-only (server-generated)Unique identifier for the tenant within the project.
tenantAdminAccessControlGroupIdintegerYesread-only (server-generated)ID of the access control group that serves as the tenant admin for this tenant.

Response example

{
  "creationTime": "2019-12-18T19:00:26.512Z",
  "id": 1888,
  "name": "Home_Base",
  "projectId": 1260
}

401 Authorization is required to access this resource.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

403 Request failed because of invalid data or denied permission.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

429 Request failed because of rate limit.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

500 An unexpected error has occurred.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.

503 The service is temporarily unavailable.

Content type: application/json

PropertyTypeRequiredConstraintsDescription
dataobjectNoread-only (server-generated)Any relevant data related to error.
reasonstringYesread-only (server-generated)Reason of error.