public ApiResponse createEntity(Entity entity) {
        assertValidApplicationId();
        if (isEmpty(entity.getType())) {
            throw new IllegalArgumentException("Missing entity type");
        }
        ApiResponse response = apiRequest(HttpMethod.POST, null, entity,
                organizationId, applicationId, entity.getType());
        return response;
    }
public ApiResponse createEntity ( Entity entity ) { assertValidApplicationId ( ) ; if ( isEmpty ( entity . getType ( ) ) ) { throw new IllegalArgumentException ( "Missing entity type" ) ; } ApiResponse response = apiRequest ( HttpMethod . POST , null , entity , organizationId , applicationId , entity . getType ( ) ) ; return response ; }
Create a new entity on the server.

@param entity
@return an ApiResponse with the new entity in it.