Modify Repository Settings

You can update settings of a repository with the specified ID added to the Veeam Backup for Microsoft Azure configuration database.

Note

You cannot change a blob container and folder for a repository.

Request

To change repository settings, send the HTTP PUT request to the /repositories/{repositoryId} endpoint. {repositoryId} is a system ID assigned to the repository in the Veeam Backup for Microsoft Azure REST API.

HTTP Request

PUT https://<hostname>/api/v2/repositories/{repositoryId}

Request Headers

The request contains the following headers.

Header

Required

Value

Description

Authorization

Required

Bearer <Access-Token>

Authenticates a client who sends the request to the server. Must contain the access token for the current logon session in the Bearer <Access-Token> format.

Request Body

To update data for the repository, send the following parameters in the request body.

Parameter

Type

Description

oldPassword

string

Specifies an old password.

name

string

Specifies a name of the repository.

description

string

Specifies a description of the  repository.

Note: If you do not send the description parameter in the request body, the value is set to null by default.

enableEncryption

boolean

Defines whether to enable encryption for backup files stored in the created  repository.

password

string

[Applies only if encryption is enabled] Specifies a password that Veeam Backup for Microsoft Azure will use for encryption.

hint

string

[Applies only if encryption is enabled] Specifies a hint for the specified password.

Note

Before you update an  repository, you can check whether settings you plan to specify for it are valid. For more information, see Validate Repository Settings.

Set the parameter values in the following format:

{

 "oldPassword": "string",

 "name": "string",

 "description": "string",

 "enableEncryption": true/false,

 "password": "string",

 "hint": "string"

}

Response

The server returns the following response to the client.

Response Codes

A successfully completed operation returns a response code 200 (OK).

Response Headers

The response to this request contains the following headers. The response may also include additional standard HTTP headers.

Header

Value

Description

Content-length

integer

Identifies the length of the response body message, in bytes.

Content-type

  • application/json
  • application/problem+json

Identifies the media type of the response body message.

Response Body

In the response body, Veeam Backup for Microsoft Azure returns an updated representation of the repository. The RepositoryV2 schema is used for the resource representation.

Modify Repository SettingsExample

The following request modifies the description and enables encryption for a repository with the ID c7aef911-cd83-4e9a-924a-e9635b0a8983.

Request:

PUT https://51.11.247.127:<%PORT%>/api/v2/repositories/c7aef911-cd83-4e9a-924a-e9635b0a8983

 

Request Header:

Authorization: Bearer <Access-Token>

Content-Type: application/json

 

Request Body:

{

 "oldPassword": "West9112#",

 "name": "Newname",

 "description": "Newdescription",

 "enableEncryption": true,

 "password": "West9112$",

 "hint": "west"

}

 

Response:

200

 

Response Body:

{

 "id": "3be6bd02-67ef-4d5b-a54e-8495e75193f0",

 "type": "RepositoryEdit",

 "status": "Pending",

 "usn": 0,

 "repositoryJobInfo": {

   "repositoryId": "2",

   "repositoryName": "Added Rep",

   "repositoryRemoved": false

 },

 "_links": {

   "self": {

     "href": "https://51.11.247.127/api/v2/jobSessions/3be6bd02-67ef-4d5b-a54e-8495e75193f0"

   },

   "log": {

     "href": "https://51.11.247.127/api/v2/jobSessions/3be6bd02-67ef-4d5b-a54e-8495e75193f0/log"

   }

 },

}

I want to report a typo

There is a misspelling right here:

 

I want to let the Veeam Documentation Team know about that.