regions/{{ID}}

PUT

Updates a Region.

Auth. Required:

Yes

Role(s) Required:

“admin” or “operator”

Response Type:

Object

Request Structure

Table 212 Request Path Parameters

Name

Description

ID

The integral, unique identifier of the region to update

division:

The new integral, unique identifier of the division which shall contain the region[1]

divisionName:

The new name of the division which shall contain the region[1]

name:

The new name of the region

#478 Request Example
PUT /api/3.0/regions/5 HTTP/1.1
Host: trafficops.infra.ciab.test
User-Agent: curl/7.47.0
Accept: */*
Cookie: mojolicious=...
Content-Length: 60
Content-Type: application/json

{
    "name": "Leeds",
    "division": 3,
    "divisionName": "England"
}

Response Structure

divisionName:

The name of the division which contains this region

divisionId:

The integral, unique identifier of the division which contains this region

id:

An integral, unique identifier for this region

lastUpdated:

The date and time at which this region was last updated, in Traffic Ops’s Custom Date/Time Format

name:

The region name

#479 Response Example
HTTP/1.1 200 OK
Access-Control-Allow-Credentials: true
Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type, Accept, Set-Cookie, Cookie
Access-Control-Allow-Methods: POST,GET,OPTIONS,PUT,DELETE
Access-Control-Allow-Origin: *
Content-Type: application/json
Set-Cookie: mojolicious=...; Path=/; Expires=Mon, 18 Nov 2019 17:40:54 GMT; Max-Age=3600; HttpOnly
Whole-Content-Sha512: 7SVj4q7dtSTNQEJlBApEwlad28WBVFnpdHaatoIpNfeLltfcpcdVTcOKB4JXQv7rlSD2p/TxBQC6EXpxwYTnKQ==
X-Server-Name: traffic_ops_golang/
Date: Thu, 06 Dec 2018 02:23:40 GMT
Content-Length: 173

{ "alerts": [
    {
        "text": "region was updated.",
        "level": "success"
    }
],
"response": {
    "divisionName": "England",
    "division": 3,
    "id": 5,
    "lastUpdated": "2018-12-06 02:23:40+00",
    "name": "Leeds"
}}