POST /properties

Request

{
	"name": "prop", //required
  "parentId": 0, //optional
  "typeId": 0, //optional 
	"isGlobal": true, //optional 
	"isGroup": false,  //optional
	"tableReference": "ref_universal", //optional
  "description": "first status", //optional
  "order": 1 //optional
}

Response

{
  "status": 1,
  "message": "",
  "response": {
      "id": 12,
			"name": "prop",
		  "parentId": 0,
		  "typeId": 0, 
			"isGlobal": true, 
			"isGroup": false, 
			"tableReference": "ref_universal",
		  "description": "first status",
		  "order": 1
    }
}

PATCH /properties

Request

{
	"id": 12, //required
	"name": "prop", //optional
  "parentId": 0, //optional
  "typeId": 0, //optional 
	"isGlobal": true, //optional 
	"isGroup": false,  //optional
	"tableReference": "ref_universal", //optional
  "description": "first status", //optional
  "order": 1 //optional
}

Response

{
  "status": 1,
  "message": "",
  "response": {
      "id": 12,
			"name": "prop",
		  "parentId": 0,
		  "typeId": 0, 
			"isGlobal": true, 
			"isGroup": false, 
			"tableReference": "ref_universal",
		  "description": "first status",
		  "order": 1
    }
}

GET /properties?q=string&offset=0

q - регистронезависимая подстрока property_name

Response

{
  "status": 1,
  "message": "",
  "response": {
	"properties": [
		{
			"id": 12, 
			"name": "prop", 
		  "parentId": 0, 
		  "typeId": 0,
			"isGlobal": true,
			"isGroup": false,  
			"tableReference": "ref_universal",
		  "description": "first status",
		  "order": 1 
		},
		{
			"id": 12, 
			"name": "prop", 
		  "parentId": 0, 
		  "typeId": 0, 
			"isGlobal": true,
			"isGroup": false,  
			"tableReference": "ref_universal", 
		  "description": "first status", 
		  "order": 1 
		}
	],
	offset: 0,
  total: 2
}
}

GET /properties/{prop_id}

Request

Response

{
  "status": 1,
  "message": "",
  "response": {
      "id": 12,
			"name": "prop",
		  "parentId": 0,
		  "typeId": 0, 
			"isGlobal": true, 
			"isGroup": false, 
			"tableReference": "ref_universal",
		  "description": "first status",
		  "order": 1
    }
}

DELETE /properties/{prop_id}

Request

Response

{
  "status": 1,
  "message": "",
  "response": {}
}

GET /properties/types

Request

Response

{
  "status": 1,
  "message": "",
  "response": {
	"propertiesTypes": [
		{
			"id": 12, 
			"name": "propType", 
		  "description": "first status", 
		  "settings": {
				<JSON>
			}
		},
		{
			"id": 12, 
			"name": "propType2", 
		  "description": "second status", 
		  "settings": {
				<JSON>
			}
		}
	],
	offset: 0,
  total: 2
}
}

POST /properties/types

Request

{
	"name": "propType", 
  "description": "first status", 
  "settings": {
		<JSON>
	}
}

Response

{
  "status": 1,
  "message": "",
  "response": {
			"id": 12, 
			"name": "propType", 
		  "description": "first status", 
		  "settings": {
				<JSON>
			}
	}
}