Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

URL: https://123.123.123.123/timeperiods/edit/$ID

Methode: POST

Response: JSON



VALUERequired for editingDescriptionTypeExample

$ID
(warning)ID for the time periodinteger1

$TIMERANGE_ID
(warning)ID for the time rangeinteger1

$CONTAINER_ID
(warning)The container ID, 1 for default root containerinteger1

$NAME(warning)The name of the time periodstring"my period 1"

$DESCRIPTION

The description of the time periodstring"my description"

$DAY(warning)

Day of the time range:

Monday => 1,

Tuesday => 2,

Wednesday => 3,

Thursday => 4,

Friday => 5,

Saturday => 6,

Sunday => 7

integer1

$START_TIME(warning)Start time of the time rangestring08:45

$END_TIME(warning)End time of the time rangestring10:50




JSON to edit a time period via REST API
"data": {
	"Timeperiod": {
   		"container_id": $CONTAINER_ID,
		"id": $ID,
		"name": "$NAME",
    	"description": "$DESCRIPTION",
	},
	"Timerange": {
    	0: {
			"id": $TIMERANGE_ID,
			"day": $DAY,
        	"start": $START_TIME,
        	"end": $END_TIME
    	},
	}
}



  • No labels