Update a Service
To update the name and description of an existing Service in your Workspace, you need to know your Workspace identifier and the Service identifier. The sample code uses a serviceId of 123 and a workspaceId of 123456. Use the actual ID values of your Workspace and Service.
Minimum Parameters for Updating a Service
The following parameters are the base parameters required to update a Service.
Update a ServiceMinimum Configuration Sample
curl 'https://mock.blazemeter.com/api/v1/workspaces/123456/services/123' \
-X PUT \
-H 'accept: */*' \
-H 'authorization: Basic Aa1Bb2Cc3Dd4Ee5Ff6Gg7Hh8Ii9Jj0Aa1Bb2Cc3Dd4Ee5Ff6' \
-H "Content-Type: application/json" \
-d '{ "description": "A service that handles foo", "id": 1645, "name": "My foo service"}'
Update a Service Request Attributes
Attributes
-
serviceIdintegerrequired
The Service identifier
-
workspaceIdintegerrequired
The Workspace identifier
-
descriptionstringrequired
The new description of the updated Service
-
namestringrequired
The new name of the updated Service
Response201 Created
{
"apiVersion": 1,
"error": null,
"result": {
"id": 123,
"name": "My Foo Service",
"description": "This service handles foo.",
"created": 1563897852,
"updated": 1563897852,
"createdBy": "someone@example.com",
"updatedBy": "someone@example.com"
},
"requestId": "d1cfe5c67b2ed26f"
}