(Quick Reference) Service: Update

Description: This web service is used to update an existing assigned customer group object to the database

Method: PUT

Request content type: application/json




NameDescriptionTypeRequiredExample values
idid of the customer group to updateLongYes111
groupIdthe id of the customer groupLongYes777
customerIdthe id of the customer to assignLongYes123

URL with external_id:



NameDescriptionTypeRequiredExamples values
customerIdreference of the customerStringYesC-002
groupIdreference of the customer groupStringYesCG-001

Success Output

Success case: response.status=201
    "id": 101,
    "customerReference": "C-003",
    "customerGroupReference": "CG-002",
    "customer": {
        "id": 1336,
        "reference": "C-003",
        "name": "cus3",
        "href": "/api/v1.0/customers/1336"
    "customerGroup": {
        "id": 6,
        "reference": "CG-002",
        "name": "CusG2",
        "href": "/api/v1.0/customerGroups/6"
    "organization": "Lyon",
    "dateCreated": "2016-08-22T11:13:12Z",
    "lastUpdated": "2016-08-22T12:44:42Z"

Failure Output

Failure case:response.status = 400
    "error": "missing_param",
    "error_description": "groupId parameter is missing"
    "error": "already_assigned",
    "error_description": "customer is already assigned to customerGroup."
     "error": "save_failed",
     "error_description": "Failed to save instance"

Failure case:response.status = 404
    "error": "not_found",
    "error_description": "The customer group with the id 999 doesn't exist."
Failure case:response.status = 500
    "error": "server_error",
    "error_description": "Oops! Something went wrong..."