Update a credential
- Zuletzt aktualisiert2020/05/12
Update a credential
Send a PUT request to update the credential name or description, attribute name or description, input type, value masking, or password flagging.
Prerequisites
- JSON Web Token (JWT)
- All Control Room APIs require a JSON Web Token (JWT) to access the APIs. Generate an authentication token using the Enterprise 11 Authentication API.
- Permissions
- You must be the owner of a credential to update credential properties.
Note:
- Use the Swagger definition files installed with your Control Room to test the APIs. View the available Swagger APIs at
http://<your_control_room_url>/swagger/
. - You can also use a REST client to complete this task.
Procedure
You can also run REST requests from a command terminal. Here is a Curl example of
the request. This example is formatted for readability. Replace text inside the angel
brackets with the appropriate
values.
curl -X POST "<your_control_room_url>/v2/credentialvault/credentials"
-H "accept: application/json" -H "X-Authorization: <authentication_token>"
-H "Content-Type: application/json" -d "{ \"id\": \"<credential_id>\",
\"name\": \"<credential_name>\", \"description\": \"<credential_description>\",
\"ownerId\": \"<owner_id>\", \"attributes\": [], \"createdBy\": \"<user_id>\",
\"createdOn\": \"<date_time>\", \"updatedBy\": \"<user_id>\",
\"updatedOn\": \"<date_time>\", \"version\": \"<version_number>\"}"