Create an instance of salesTerritories

post

/services/rest/connect/v1.4/salesTerritories

Request

Body ()
A specific geographical sales region
Root Schema : salesTerritories
Type: object
A specific geographical sales region
Show Source
Nested Schema : namedIDs-salesTerritories-adminVisibleInterfaces
Type: object
Named ID that can be included in a list
Show Source
  • Minimum Value: 1
    Maximum Value: 9.223372036854776E18
    ID value. This is the key for the list entry.
  • Maximum Length: 255
    Name used to lookup this object
Nested Schema : salesTerritories-names
Type: object
Strings that are language-specific, allowing localization of fields. Like the Label class, but the label text cannot be empty or null. Labels will be assembled in a list that is associated with one particular text field
Show Source
Nested Schema : namedIDs-salesTerritories-names-language
Type: object
An ID which has an associated name string. These IDs can be set by either value or name. If the name cannot uniquely determine the value, an error is generated.
Show Source

Response

Default Response

Body ()
A specific geographical sales region
Root Schema : salesTerritories
Type: object
A specific geographical sales region
Show Source
Nested Schema : namedIDs-salesTerritories-adminVisibleInterfaces
Type: object
Named ID that can be included in a list
Show Source
  • Minimum Value: 1
    Maximum Value: 9.223372036854776E18
    ID value. This is the key for the list entry.
  • Maximum Length: 255
    Name used to lookup this object
Nested Schema : salesTerritories-names
Type: object
Strings that are language-specific, allowing localization of fields. Like the Label class, but the label text cannot be empty or null. Labels will be assembled in a list that is associated with one particular text field
Show Source
Nested Schema : namedIDs-salesTerritories-names-language
Type: object
An ID which has an associated name string. These IDs can be set by either value or name. If the name cannot uniquely determine the value, an error is generated.
Show Source

Examples

Use POST with the following syntax to create a new sales territory object:

https://your_site_interface/services/rest/connect/version/salesTerritories

Request URI example

https://mysite.example.com/services/rest/connect/v1.4/salesTerritories

Request body example

{
"names": [
    {
    "labelText": "Quebec",
    "language":
        {
        "id":1
        }
    },
    {
    "labelText": "Qu??bec",
    "language":
        {
        "id":8
        }
    }
    ]
}

Note:

The names array is required for sales territories. It contains a list of names, one for each supported language.

Response body example

{
  "id": 12,
  "lookupName": "Quebec",
  "adminVisibleInterfaces": {
    "links": [
      {
        "rel": "self",
        "href": "https://mysite.example.com/services/rest/connect/v1.4/salesTerritories/12/adminVisibleInterfaces"
      }
    ]
  },
  "comment": null,
  "disabled": false,
  "displayOrder": 7,
  "name": "Quebec",
  "names": {
    "links": [
      {
        "rel": "self",
        "href": "https://mysite.example.com/services/rest/connect/v1.4/salesTerritories/12/names"
      }
    ]
  },
  "parent": null,
  "territoryHierarchy": {
    "links": [
      {
        "rel": "self",
        "href": "https://mysite.example.com/services/rest/connect/v1.4/salesTerritories/12/territoryHierarchy"
      }
    ]
  },
  "links": [
    {
      "rel": "self",
      "href": "https://mysite.example.com/services/rest/connect/v1.4/salesTerritories/12"
    },
    {
      "rel": "canonical",
      "href": "https://mysite.example.com/services/rest/connect/v1.4/salesTerritories/12"
    },
    {
      "rel": "describedby",
      "href": "https://mysite.example.com/services/rest/connect/v1.4/metadata-catalog/salesTerritories",
      "mediaType": "application/schema+json"
    }
  ]
}