Follow

Update or Create Region

If a region with the same Id already exists then that region will be updated.

 

Attributes 

Attribute

Value

Path

/v3/regions

Support Formats

JSON, XML

HTTP Method

POST

Secure

Yes

Rate Limited

No

Cache Timeout

TBC

HTTP Codes

·        200 - OK

·        400 - Bad Request. 

·        500 - Internal Server Error. 

 

Request

The following table contains the details of a typical HTTP Request for this service:

Type

Value

Header

POST /v3/regions HTTP/1.1

Host: merchant.api.vmob.co

Content-Type: application/json

Accept-Language: en-US

x-vmob-authorization: dm1vYi53aW5kb3dzLjE6

Body 

{

    "Id": 2,

    "Name": "Telemark",

    "Latitude": "58.869300000",

    "Longitude": "9.414940000",

    "PolygonBoundsCoordinates": "58.938673,9.838257|59.164668,9.821777|59.179974,9.893188|

                                 59.216542,9.865723|59.258686,9.876709|59.328811,9.766846|

                                 59.415566,9.777832|59.418361,9.629517|59.488157,9.547119|

                                 59.499311,9.453735|59.549459,9.503174|59.682821,9.398804"

}

 

Successful Response

The following table contains the details of a typical successful HTTP Request for this service. 

Type

Value

Header

HTTP/1.1 200 OK

Content-Type: application/json

Cache-Control: no-store

Pragma: no-cache

Body

"2"

Notes: return value is the region Id if it creates a new region, otherwise return = 0

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.