azure-arm-powerbiembedded
Advanced tools
Comparing version 0.1.1 to 1.0.0-preview
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,42 +19,44 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
*/ | ||
function AzureSku() { | ||
} | ||
class AzureSku { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of AzureSku | ||
* | ||
* @returns {object} metadata of AzureSku | ||
* | ||
*/ | ||
AzureSku.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'AzureSku', | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku', | ||
modelProperties: { | ||
name: { | ||
required: true, | ||
isConstant: true, | ||
serializedName: 'name', | ||
defaultValue: 'S1', | ||
type: { | ||
name: 'String' | ||
/** | ||
* Defines the metadata of AzureSku | ||
* | ||
* @returns {object} metadata of AzureSku | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'AzureSku', | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku', | ||
modelProperties: { | ||
name: { | ||
required: true, | ||
isConstant: true, | ||
serializedName: 'name', | ||
defaultValue: 'S1', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
tier: { | ||
required: true, | ||
isConstant: true, | ||
serializedName: 'tier', | ||
defaultValue: 'Standard', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
tier: { | ||
required: true, | ||
isConstant: true, | ||
serializedName: 'tier', | ||
defaultValue: 'Standard', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = AzureSku; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,44 +19,46 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [name] Workspace collection name | ||
* | ||
* | ||
* @member {string} [type] Resource type. Default value: | ||
* 'Microsoft.PowerBI/workspaceCollections' . | ||
* | ||
* | ||
*/ | ||
function CheckNameRequest() { | ||
} | ||
class CheckNameRequest { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of CheckNameRequest | ||
* | ||
* @returns {object} metadata of CheckNameRequest | ||
* | ||
*/ | ||
CheckNameRequest.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'CheckNameRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'CheckNameRequest', | ||
modelProperties: { | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
/** | ||
* Defines the metadata of CheckNameRequest | ||
* | ||
* @returns {object} metadata of CheckNameRequest | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'CheckNameRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'CheckNameRequest', | ||
modelProperties: { | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
type: { | ||
name: 'String' | ||
required: false, | ||
serializedName: 'type', | ||
defaultValue: 'Microsoft.PowerBI/workspaceCollections', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
type: { | ||
required: false, | ||
serializedName: 'type', | ||
defaultValue: 'Microsoft.PowerBI/workspaceCollections', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = CheckNameRequest; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -21,53 +21,55 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* use. | ||
* | ||
* @member {string} [reason] Reason why the workspace collection name cannot | ||
* be used. Possible values include: 'Unavailable', 'Invalid' | ||
* | ||
* | ||
* @member {string} [reason] Reason why the workspace collection name cannot be | ||
* used. Possible values include: 'Unavailable', 'Invalid' | ||
* | ||
* @member {string} [message] Message indicating an unavailable name due to a | ||
* conflict or a description of the naming rules that are violated. | ||
* | ||
* conflict, or a description of the naming rules that are violated. | ||
* | ||
*/ | ||
function CheckNameResponse() { | ||
} | ||
class CheckNameResponse { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of CheckNameResponse | ||
* | ||
* @returns {object} metadata of CheckNameResponse | ||
* | ||
*/ | ||
CheckNameResponse.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'CheckNameResponse', | ||
type: { | ||
name: 'Composite', | ||
className: 'CheckNameResponse', | ||
modelProperties: { | ||
nameAvailable: { | ||
required: false, | ||
serializedName: 'nameAvailable', | ||
type: { | ||
name: 'Boolean' | ||
/** | ||
* Defines the metadata of CheckNameResponse | ||
* | ||
* @returns {object} metadata of CheckNameResponse | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'CheckNameResponse', | ||
type: { | ||
name: 'Composite', | ||
className: 'CheckNameResponse', | ||
modelProperties: { | ||
nameAvailable: { | ||
required: false, | ||
serializedName: 'nameAvailable', | ||
type: { | ||
name: 'Boolean' | ||
} | ||
}, | ||
reason: { | ||
required: false, | ||
serializedName: 'reason', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
reason: { | ||
required: false, | ||
serializedName: 'reason', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = CheckNameResponse; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,3 +14,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
@@ -22,59 +22,61 @@ /** | ||
* @member {string} [location] Azure location | ||
* | ||
* | ||
* @member {object} [tags] | ||
* | ||
* | ||
*/ | ||
function CreateWorkspaceCollectionRequest() { | ||
} | ||
class CreateWorkspaceCollectionRequest { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of CreateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of CreateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
CreateWorkspaceCollectionRequest.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'CreateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'CreateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
location: { | ||
required: false, | ||
serializedName: 'location', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
/** | ||
* Defines the metadata of CreateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of CreateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'CreateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'CreateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
location: { | ||
required: false, | ||
serializedName: 'location', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = CreateWorkspaceCollectionRequest; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,82 +19,84 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [provider] The localized friendly form of the resource | ||
* provider name – it is expected to also include the publisher/company | ||
* responsible. It should use Title Casing and begin with “Microsoft” for 1st | ||
* party services. | ||
* | ||
* @member {string} [resource] The localized friendly form of the resource | ||
* type related to this action/operation – it should match the public | ||
* documentation for the resource provider. It should use Title Casing – for | ||
* examples, please refer to the “name” section. | ||
* | ||
* @member {string} [operation] The localized friendly name for the operation, | ||
* as it should be shown to the user. It should be concise (to fit in drop | ||
* downs) but clear (i.e. self-documenting). It should use Title Casing and | ||
* include the entity/resource to which it applies. | ||
* | ||
* provider name. This form is also expected to include the publisher/company | ||
* responsible. Use Title Casing. Begin with “Microsoft” for 1st party | ||
* services. | ||
* | ||
* @member {string} [resource] The localized friendly form of the resource type | ||
* related to this action/operation. This form should match the public | ||
* documentation for the resource provider. Use Title Casing. For examples, | ||
* refer to the “name” section. | ||
* | ||
* @member {string} [operation] The localized friendly name for the operation | ||
* as shown to the user. This name should be concise (to fit in drop downs), | ||
* but clear (self-documenting). Use Title Casing and include the | ||
* entity/resource to which it applies. | ||
* | ||
* @member {string} [description] The localized friendly description for the | ||
* operation, as it should be shown to the user. It should be thorough, yet | ||
* concise – it will be used in tool tips and detailed views. | ||
* | ||
* operation as shown to the user. This description should be thorough, yet | ||
* concise. It will be used in tool-tips and detailed views. | ||
* | ||
* @member {string} [origin] The intended executor of the operation; governs | ||
* the display of the operation in the RBAC UX and the audit logs UX. Default | ||
* value is 'user,system' | ||
* | ||
* | ||
*/ | ||
function Display() { | ||
} | ||
class Display { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of Display | ||
* | ||
* @returns {object} metadata of Display | ||
* | ||
*/ | ||
Display.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'Display', | ||
type: { | ||
name: 'Composite', | ||
className: 'Display', | ||
modelProperties: { | ||
provider: { | ||
required: false, | ||
serializedName: 'provider', | ||
type: { | ||
name: 'String' | ||
/** | ||
* Defines the metadata of Display | ||
* | ||
* @returns {object} metadata of Display | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'Display', | ||
type: { | ||
name: 'Composite', | ||
className: 'Display', | ||
modelProperties: { | ||
provider: { | ||
required: false, | ||
serializedName: 'provider', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
resource: { | ||
required: false, | ||
serializedName: 'resource', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
operation: { | ||
required: false, | ||
serializedName: 'operation', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
description: { | ||
required: false, | ||
serializedName: 'description', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
origin: { | ||
required: false, | ||
serializedName: 'origin', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
resource: { | ||
required: false, | ||
serializedName: 'resource', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
operation: { | ||
required: false, | ||
serializedName: 'operation', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
description: { | ||
required: false, | ||
serializedName: 'description', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
origin: { | ||
required: false, | ||
serializedName: 'origin', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = Display; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,51 +19,53 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [code] | ||
* | ||
* | ||
* @member {string} [message] | ||
* | ||
* | ||
* @member {string} [target] | ||
* | ||
* | ||
*/ | ||
function ErrorDetail() { | ||
} | ||
class ErrorDetail { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of ErrorDetail | ||
* | ||
* @returns {object} metadata of ErrorDetail | ||
* | ||
*/ | ||
ErrorDetail.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'ErrorDetail', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorDetail', | ||
modelProperties: { | ||
code: { | ||
required: false, | ||
serializedName: 'code', | ||
type: { | ||
name: 'String' | ||
/** | ||
* Defines the metadata of ErrorDetail | ||
* | ||
* @returns {object} metadata of ErrorDetail | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'ErrorDetail', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorDetail', | ||
modelProperties: { | ||
code: { | ||
required: false, | ||
serializedName: 'code', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
target: { | ||
required: false, | ||
serializedName: 'target', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
target: { | ||
required: false, | ||
serializedName: 'target', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = ErrorDetail; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,6 +14,4 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
var util = require('util'); | ||
/** | ||
@@ -24,68 +22,70 @@ * @class | ||
* @member {string} [code] | ||
* | ||
* | ||
* @member {string} [message] | ||
* | ||
* | ||
* @member {string} [target] | ||
* | ||
* | ||
* @member {array} [details] | ||
* | ||
* | ||
*/ | ||
function ErrorModel() { | ||
} | ||
class ErrorModel { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of ErrorModel | ||
* | ||
* @returns {object} metadata of ErrorModel | ||
* | ||
*/ | ||
ErrorModel.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'Error', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorModel', | ||
modelProperties: { | ||
code: { | ||
required: false, | ||
serializedName: 'code', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
target: { | ||
required: false, | ||
serializedName: 'target', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
details: { | ||
required: false, | ||
serializedName: 'details', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'ErrorDetailElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorDetail' | ||
} | ||
/** | ||
* Defines the metadata of ErrorModel | ||
* | ||
* @returns {object} metadata of ErrorModel | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'Error', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorModel', | ||
modelProperties: { | ||
code: { | ||
required: false, | ||
serializedName: 'code', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
message: { | ||
required: false, | ||
serializedName: 'message', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
target: { | ||
required: false, | ||
serializedName: 'target', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
details: { | ||
required: false, | ||
serializedName: 'details', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'ErrorDetailElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'ErrorDetail' | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = ErrorModel; |
@@ -5,28 +5,30 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
* Changes may cause incorrect behavior and will be lost if the code is | ||
* regenerated. | ||
// TODO: Include PageTemplateModels here too?? Probably | ||
*/ | ||
import { BaseResource } from 'ms-rest-azure'; | ||
import { CloudError } from 'ms-rest-azure'; | ||
export { BaseResource } from 'ms-rest-azure'; | ||
export { CloudError } from 'ms-rest-azure'; | ||
/** | ||
* @class | ||
* Initializes a new instance of the ErrorModel class. | ||
* Initializes a new instance of the ErrorDetail class. | ||
* @constructor | ||
* @member {string} [code] | ||
* | ||
* | ||
* @member {string} [message] | ||
* | ||
* | ||
* @member {string} [target] | ||
* | ||
* @member {array} [details] | ||
* | ||
* | ||
*/ | ||
export interface ErrorModel { | ||
code?: string; | ||
message?: string; | ||
target?: string; | ||
details?: ErrorDetail[]; | ||
export interface ErrorDetail { | ||
code?: string; | ||
message?: string; | ||
target?: string; | ||
} | ||
@@ -36,15 +38,18 @@ | ||
* @class | ||
* Initializes a new instance of the ErrorDetail class. | ||
* Initializes a new instance of the ErrorModel class. | ||
* @constructor | ||
* @member {string} [code] | ||
* | ||
* | ||
* @member {string} [message] | ||
* | ||
* | ||
* @member {string} [target] | ||
* | ||
* | ||
* @member {array} [details] | ||
* | ||
*/ | ||
export interface ErrorDetail { | ||
code?: string; | ||
message?: string; | ||
target?: string; | ||
export interface ErrorModel { | ||
code?: string; | ||
message?: string; | ||
target?: string; | ||
details?: ErrorDetail[]; | ||
} | ||
@@ -54,24 +59,32 @@ | ||
* @class | ||
* Initializes a new instance of the AzureSku class. | ||
* @constructor | ||
*/ | ||
export interface AzureSku { | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the WorkspaceCollection class. | ||
* @constructor | ||
* @member {string} [id] Resource id | ||
* | ||
* | ||
* @member {string} [name] Workspace collection name | ||
* | ||
* | ||
* @member {string} [type] Resource type | ||
* | ||
* | ||
* @member {string} [location] Azure location | ||
* | ||
* | ||
* @member {object} [tags] | ||
* | ||
* | ||
* @member {object} [properties] Properties | ||
* | ||
* | ||
*/ | ||
export interface WorkspaceCollection { | ||
id?: string; | ||
name?: string; | ||
type?: string; | ||
location?: string; | ||
tags?: { [propertyName: string]: string }; | ||
properties?: any; | ||
id?: string; | ||
name?: string; | ||
type?: string; | ||
location?: string; | ||
tags?: { [propertyName: string]: string }; | ||
properties?: any; | ||
} | ||
@@ -81,6 +94,9 @@ | ||
* @class | ||
* Initializes a new instance of the AzureSku class. | ||
* Initializes a new instance of the WorkspaceCollectionList class. | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
*/ | ||
export interface AzureSku { | ||
export interface WorkspaceCollectionList { | ||
value?: WorkspaceCollection[]; | ||
} | ||
@@ -93,15 +109,15 @@ | ||
* @member {string} [id] Workspace id | ||
* | ||
* | ||
* @member {string} [name] Workspace name | ||
* | ||
* | ||
* @member {string} [type] Resource type | ||
* | ||
* | ||
* @member {object} [properties] Property bag | ||
* | ||
* | ||
*/ | ||
export interface Workspace { | ||
id?: string; | ||
name?: string; | ||
type?: string; | ||
properties?: any; | ||
id?: string; | ||
name?: string; | ||
type?: string; | ||
properties?: any; | ||
} | ||
@@ -111,9 +127,9 @@ | ||
* @class | ||
* Initializes a new instance of the OperationList class. | ||
* Initializes a new instance of the WorkspaceList class. | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
* | ||
*/ | ||
export interface OperationList { | ||
value?: Operation[]; | ||
export interface WorkspaceList { | ||
value?: Workspace[]; | ||
} | ||
@@ -123,37 +139,73 @@ | ||
* @class | ||
* Initializes a new instance of the Display class. | ||
* @constructor | ||
* @member {string} [provider] The localized friendly form of the resource | ||
* provider name. This form is also expected to include the publisher/company | ||
* responsible. Use Title Casing. Begin with “Microsoft” for 1st party | ||
* services. | ||
* | ||
* @member {string} [resource] The localized friendly form of the resource type | ||
* related to this action/operation. This form should match the public | ||
* documentation for the resource provider. Use Title Casing. For examples, | ||
* refer to the “name” section. | ||
* | ||
* @member {string} [operation] The localized friendly name for the operation | ||
* as shown to the user. This name should be concise (to fit in drop downs), | ||
* but clear (self-documenting). Use Title Casing and include the | ||
* entity/resource to which it applies. | ||
* | ||
* @member {string} [description] The localized friendly description for the | ||
* operation as shown to the user. This description should be thorough, yet | ||
* concise. It will be used in tool-tips and detailed views. | ||
* | ||
* @member {string} [origin] The intended executor of the operation; governs | ||
* the display of the operation in the RBAC UX and the audit logs UX. Default | ||
* value is 'user,system' | ||
* | ||
*/ | ||
export interface Display { | ||
provider?: string; | ||
resource?: string; | ||
operation?: string; | ||
description?: string; | ||
origin?: string; | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the Operation class. | ||
* @constructor | ||
* @member {string} [name] The name of the operation being performed on this | ||
* particular object. It should match the action name that appears in RBAC / | ||
* the event service. | ||
* | ||
* particular object. This name should match the action name that appears in | ||
* RBAC / the event service. | ||
* | ||
* @member {object} [display] | ||
* | ||
* | ||
* @member {string} [display.provider] The localized friendly form of the | ||
* resource provider name – it is expected to also include the | ||
* publisher/company responsible. It should use Title Casing and begin with | ||
* “Microsoft” for 1st party services. | ||
* | ||
* resource provider name. This form is also expected to include the | ||
* publisher/company responsible. Use Title Casing. Begin with “Microsoft” for | ||
* 1st party services. | ||
* | ||
* @member {string} [display.resource] The localized friendly form of the | ||
* resource type related to this action/operation – it should match the | ||
* public documentation for the resource provider. It should use Title Casing | ||
* – for examples, please refer to the “name” section. | ||
* | ||
* resource type related to this action/operation. This form should match the | ||
* public documentation for the resource provider. Use Title Casing. For | ||
* examples, refer to the “name” section. | ||
* | ||
* @member {string} [display.operation] The localized friendly name for the | ||
* operation, as it should be shown to the user. It should be concise (to fit | ||
* in drop downs) but clear (i.e. self-documenting). It should use Title | ||
* Casing and include the entity/resource to which it applies. | ||
* | ||
* operation as shown to the user. This name should be concise (to fit in drop | ||
* downs), but clear (self-documenting). Use Title Casing and include the | ||
* entity/resource to which it applies. | ||
* | ||
* @member {string} [display.description] The localized friendly description | ||
* for the operation, as it should be shown to the user. It should be | ||
* thorough, yet concise – it will be used in tool tips and detailed views. | ||
* | ||
* for the operation as shown to the user. This description should be thorough, | ||
* yet concise. It will be used in tool-tips and detailed views. | ||
* | ||
* @member {string} [display.origin] The intended executor of the operation; | ||
* governs the display of the operation in the RBAC UX and the audit logs UX. | ||
* Default value is 'user,system' | ||
* | ||
* | ||
*/ | ||
export interface Operation { | ||
name?: string; | ||
display?: Display; | ||
name?: string; | ||
display?: Display; | ||
} | ||
@@ -163,34 +215,9 @@ | ||
* @class | ||
* Initializes a new instance of the Display class. | ||
* Initializes a new instance of the OperationList class. | ||
* @constructor | ||
* @member {string} [provider] The localized friendly form of the resource | ||
* provider name – it is expected to also include the publisher/company | ||
* responsible. It should use Title Casing and begin with “Microsoft” for 1st | ||
* party services. | ||
* | ||
* @member {string} [resource] The localized friendly form of the resource | ||
* type related to this action/operation – it should match the public | ||
* documentation for the resource provider. It should use Title Casing – for | ||
* examples, please refer to the “name” section. | ||
* | ||
* @member {string} [operation] The localized friendly name for the operation, | ||
* as it should be shown to the user. It should be concise (to fit in drop | ||
* downs) but clear (i.e. self-documenting). It should use Title Casing and | ||
* include the entity/resource to which it applies. | ||
* | ||
* @member {string} [description] The localized friendly description for the | ||
* operation, as it should be shown to the user. It should be thorough, yet | ||
* concise – it will be used in tool tips and detailed views. | ||
* | ||
* @member {string} [origin] The intended executor of the operation; governs | ||
* the display of the operation in the RBAC UX and the audit logs UX. Default | ||
* value is 'user,system' | ||
* | ||
* @member {array} [value] | ||
* | ||
*/ | ||
export interface Display { | ||
provider?: string; | ||
resource?: string; | ||
operation?: string; | ||
description?: string; | ||
origin?: string; | ||
export interface OperationList { | ||
value?: Operation[]; | ||
} | ||
@@ -203,9 +230,9 @@ | ||
* @member {string} [key1] Access key 1 | ||
* | ||
* | ||
* @member {string} [key2] Access key 2 | ||
* | ||
* | ||
*/ | ||
export interface WorkspaceCollectionAccessKeys { | ||
key1?: string; | ||
key2?: string; | ||
key1?: string; | ||
key2?: string; | ||
} | ||
@@ -218,6 +245,6 @@ | ||
* @member {string} [keyName] Key name. Possible values include: 'key1', 'key2' | ||
* | ||
* | ||
*/ | ||
export interface WorkspaceCollectionAccessKey { | ||
keyName?: string; | ||
keyName?: string; | ||
} | ||
@@ -230,9 +257,9 @@ | ||
* @member {string} [location] Azure location | ||
* | ||
* | ||
* @member {object} [tags] | ||
* | ||
* | ||
*/ | ||
export interface CreateWorkspaceCollectionRequest { | ||
location?: string; | ||
tags?: { [propertyName: string]: string }; | ||
location?: string; | ||
tags?: { [propertyName: string]: string }; | ||
} | ||
@@ -245,6 +272,6 @@ | ||
* @member {object} [tags] | ||
* | ||
* | ||
*/ | ||
export interface UpdateWorkspaceCollectionRequest { | ||
tags?: { [propertyName: string]: string }; | ||
tags?: { [propertyName: string]: string }; | ||
} | ||
@@ -257,9 +284,10 @@ | ||
* @member {string} [name] Workspace collection name | ||
* | ||
* @member {string} [type] Resource type | ||
* | ||
* | ||
* @member {string} [type] Resource type. Default value: | ||
* 'Microsoft.PowerBI/workspaceCollections' . | ||
* | ||
*/ | ||
export interface CheckNameRequest { | ||
name?: string; | ||
type?: string; | ||
name?: string; | ||
type?: string; | ||
} | ||
@@ -274,14 +302,14 @@ | ||
* use. | ||
* | ||
* @member {string} [reason] Reason why the workspace collection name cannot | ||
* be used. Possible values include: 'Unavailable', 'Invalid' | ||
* | ||
* | ||
* @member {string} [reason] Reason why the workspace collection name cannot be | ||
* used. Possible values include: 'Unavailable', 'Invalid' | ||
* | ||
* @member {string} [message] Message indicating an unavailable name due to a | ||
* conflict or a description of the naming rules that are violated. | ||
* | ||
* conflict, or a description of the naming rules that are violated. | ||
* | ||
*/ | ||
export interface CheckNameResponse { | ||
nameAvailable?: boolean; | ||
reason?: string; | ||
message?: string; | ||
nameAvailable?: boolean; | ||
reason?: string; | ||
message?: string; | ||
} | ||
@@ -293,11 +321,50 @@ | ||
* @constructor | ||
* @member {string} [targetResourceGroup] Name of the resource group that the | ||
* Power BI Workspace Collections will be migrated to. | ||
* | ||
* @member {string} [targetResourceGroup] Name of the resource group the Power | ||
* BI workspace collections will be migrated to. | ||
* | ||
* @member {array} [resources] | ||
* | ||
* | ||
*/ | ||
export interface MigrateWorkspaceCollectionRequest { | ||
targetResourceGroup?: string; | ||
resources?: string[]; | ||
targetResourceGroup?: string; | ||
resources?: string[]; | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the WorkspaceCollectionList class. | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
*/ | ||
export interface WorkspaceCollectionList { | ||
value?: WorkspaceCollection[]; | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the WorkspaceList class. | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
*/ | ||
export interface WorkspaceList { | ||
value?: Workspace[]; | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the WorkspaceCollectionList class. | ||
* @constructor | ||
*/ | ||
export interface WorkspaceCollectionList extends Array<WorkspaceCollection> { | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the WorkspaceList class. | ||
* @constructor | ||
*/ | ||
export interface WorkspaceList extends Array<Workspace> { | ||
} |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -22,10 +22,12 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
exports.CloudError = msRestAzure.CloudError; | ||
exports.ErrorDetail = require('./errorDetail'); | ||
exports.ErrorModel = require('./errorModel'); | ||
exports.ErrorDetail = require('./errorDetail'); | ||
exports.AzureSku = require('./azureSku'); | ||
exports.WorkspaceCollection = require('./workspaceCollection'); | ||
exports.AzureSku = require('./azureSku'); | ||
exports.WorkspaceCollectionList = require('./workspaceCollectionList'); | ||
exports.Workspace = require('./workspace'); | ||
exports.WorkspaceList = require('./workspaceList'); | ||
exports.Display = require('./display'); | ||
exports.Operation = require('./operation'); | ||
exports.OperationList = require('./operationList'); | ||
exports.Operation = require('./operation'); | ||
exports.Display = require('./display'); | ||
exports.WorkspaceCollectionAccessKeys = require('./workspaceCollectionAccessKeys'); | ||
@@ -32,0 +34,0 @@ exports.WorkspaceCollectionAccessKey = require('./workspaceCollectionAccessKey'); |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,4 +14,2 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var util = require('util'); | ||
/** | ||
@@ -21,51 +19,53 @@ * @class | ||
* @constructor | ||
* @member {string} [targetResourceGroup] Name of the resource group that the | ||
* Power BI Workspace Collections will be migrated to. | ||
* | ||
* @member {string} [targetResourceGroup] Name of the resource group the Power | ||
* BI workspace collections will be migrated to. | ||
* | ||
* @member {array} [resources] | ||
* | ||
* | ||
*/ | ||
function MigrateWorkspaceCollectionRequest() { | ||
} | ||
class MigrateWorkspaceCollectionRequest { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of MigrateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of MigrateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
MigrateWorkspaceCollectionRequest.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'MigrateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'MigrateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
targetResourceGroup: { | ||
required: false, | ||
serializedName: 'targetResourceGroup', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
resources: { | ||
required: false, | ||
serializedName: 'resources', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
/** | ||
* Defines the metadata of MigrateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of MigrateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'MigrateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'MigrateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
targetResourceGroup: { | ||
required: false, | ||
serializedName: 'targetResourceGroup', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
resources: { | ||
required: false, | ||
serializedName: 'resources', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = MigrateWorkspaceCollectionRequest; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,3 +14,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
@@ -22,68 +22,70 @@ /** | ||
* @member {string} [name] The name of the operation being performed on this | ||
* particular object. It should match the action name that appears in RBAC / | ||
* the event service. | ||
* | ||
* particular object. This name should match the action name that appears in | ||
* RBAC / the event service. | ||
* | ||
* @member {object} [display] | ||
* | ||
* | ||
* @member {string} [display.provider] The localized friendly form of the | ||
* resource provider name – it is expected to also include the | ||
* publisher/company responsible. It should use Title Casing and begin with | ||
* “Microsoft” for 1st party services. | ||
* | ||
* resource provider name. This form is also expected to include the | ||
* publisher/company responsible. Use Title Casing. Begin with “Microsoft” for | ||
* 1st party services. | ||
* | ||
* @member {string} [display.resource] The localized friendly form of the | ||
* resource type related to this action/operation – it should match the | ||
* public documentation for the resource provider. It should use Title Casing | ||
* – for examples, please refer to the “name” section. | ||
* | ||
* resource type related to this action/operation. This form should match the | ||
* public documentation for the resource provider. Use Title Casing. For | ||
* examples, refer to the “name” section. | ||
* | ||
* @member {string} [display.operation] The localized friendly name for the | ||
* operation, as it should be shown to the user. It should be concise (to fit | ||
* in drop downs) but clear (i.e. self-documenting). It should use Title | ||
* Casing and include the entity/resource to which it applies. | ||
* | ||
* operation as shown to the user. This name should be concise (to fit in drop | ||
* downs), but clear (self-documenting). Use Title Casing and include the | ||
* entity/resource to which it applies. | ||
* | ||
* @member {string} [display.description] The localized friendly description | ||
* for the operation, as it should be shown to the user. It should be | ||
* thorough, yet concise – it will be used in tool tips and detailed views. | ||
* | ||
* for the operation as shown to the user. This description should be thorough, | ||
* yet concise. It will be used in tool-tips and detailed views. | ||
* | ||
* @member {string} [display.origin] The intended executor of the operation; | ||
* governs the display of the operation in the RBAC UX and the audit logs UX. | ||
* Default value is 'user,system' | ||
* | ||
* | ||
*/ | ||
function Operation() { | ||
} | ||
class Operation { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of Operation | ||
* | ||
* @returns {object} metadata of Operation | ||
* | ||
*/ | ||
Operation.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'Operation', | ||
type: { | ||
name: 'Composite', | ||
className: 'Operation', | ||
modelProperties: { | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
/** | ||
* Defines the metadata of Operation | ||
* | ||
* @returns {object} metadata of Operation | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'Operation', | ||
type: { | ||
name: 'Composite', | ||
className: 'Operation', | ||
modelProperties: { | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
display: { | ||
required: false, | ||
serializedName: 'display', | ||
type: { | ||
name: 'Composite', | ||
className: 'Display' | ||
} | ||
} | ||
}, | ||
display: { | ||
required: false, | ||
serializedName: 'display', | ||
type: { | ||
name: 'Composite', | ||
className: 'Display' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = Operation; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,6 +14,4 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
var util = require('util'); | ||
/** | ||
@@ -24,33 +22,35 @@ * @class | ||
* @member {array} [value] | ||
* | ||
* | ||
*/ | ||
function OperationList() { | ||
} | ||
class OperationList { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of OperationList | ||
* | ||
* @returns {object} metadata of OperationList | ||
* | ||
*/ | ||
OperationList.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'OperationList', | ||
type: { | ||
name: 'Composite', | ||
className: 'OperationList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: 'value', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'OperationElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'Operation' | ||
} | ||
/** | ||
* Defines the metadata of OperationList | ||
* | ||
* @returns {object} metadata of OperationList | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'OperationList', | ||
type: { | ||
name: 'Composite', | ||
className: 'OperationList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: 'value', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'OperationElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'Operation' | ||
} | ||
} | ||
} | ||
@@ -60,6 +60,6 @@ } | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = OperationList; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,3 +14,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
@@ -22,50 +22,52 @@ /** | ||
* @member {object} [tags] | ||
* | ||
* | ||
*/ | ||
function UpdateWorkspaceCollectionRequest() { | ||
} | ||
class UpdateWorkspaceCollectionRequest { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of UpdateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of UpdateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
UpdateWorkspaceCollectionRequest.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'UpdateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'UpdateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
/** | ||
* Defines the metadata of UpdateWorkspaceCollectionRequest | ||
* | ||
* @returns {object} metadata of UpdateWorkspaceCollectionRequest | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'UpdateWorkspaceCollectionRequest', | ||
type: { | ||
name: 'Composite', | ||
className: 'UpdateWorkspaceCollectionRequest', | ||
modelProperties: { | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = UpdateWorkspaceCollectionRequest; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,60 +19,62 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [id] Workspace id | ||
* | ||
* | ||
* @member {string} [name] Workspace name | ||
* | ||
* | ||
* @member {string} [type] Resource type | ||
* | ||
* | ||
* @member {object} [properties] Property bag | ||
* | ||
* | ||
*/ | ||
function Workspace() { | ||
} | ||
class Workspace { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of Workspace | ||
* | ||
* @returns {object} metadata of Workspace | ||
* | ||
*/ | ||
Workspace.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'Workspace', | ||
type: { | ||
name: 'Composite', | ||
className: 'Workspace', | ||
modelProperties: { | ||
id: { | ||
required: false, | ||
serializedName: 'id', | ||
/** | ||
* Defines the metadata of Workspace | ||
* | ||
* @returns {object} metadata of Workspace | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'Workspace', | ||
type: { | ||
name: 'Composite', | ||
className: 'Workspace', | ||
modelProperties: { | ||
id: { | ||
required: false, | ||
serializedName: 'id', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
type: { | ||
name: 'String' | ||
required: false, | ||
serializedName: 'type', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
properties: { | ||
required: false, | ||
serializedName: 'properties', | ||
type: { | ||
name: 'Object' | ||
} | ||
} | ||
}, | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
type: { | ||
required: false, | ||
serializedName: 'type', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
properties: { | ||
required: false, | ||
serializedName: 'properties', | ||
type: { | ||
name: 'Object' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = Workspace; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,3 +14,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var models = require('./index'); | ||
const models = require('./index'); | ||
@@ -22,95 +22,97 @@ /** | ||
* @member {string} [id] Resource id | ||
* | ||
* | ||
* @member {string} [name] Workspace collection name | ||
* | ||
* | ||
* @member {string} [type] Resource type | ||
* | ||
* | ||
* @member {string} [location] Azure location | ||
* | ||
* | ||
* @member {object} [tags] | ||
* | ||
* | ||
* @member {object} [properties] Properties | ||
* | ||
* | ||
*/ | ||
function WorkspaceCollection() { | ||
} | ||
class WorkspaceCollection { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of WorkspaceCollection | ||
* | ||
* @returns {object} metadata of WorkspaceCollection | ||
* | ||
*/ | ||
WorkspaceCollection.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollection', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollection', | ||
modelProperties: { | ||
id: { | ||
required: false, | ||
serializedName: 'id', | ||
/** | ||
* Defines the metadata of WorkspaceCollection | ||
* | ||
* @returns {object} metadata of WorkspaceCollection | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollection', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollection', | ||
modelProperties: { | ||
id: { | ||
required: false, | ||
serializedName: 'id', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
name: { | ||
required: false, | ||
serializedName: 'name', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
type: { | ||
required: false, | ||
serializedName: 'type', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
location: { | ||
required: false, | ||
serializedName: 'location', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
required: false, | ||
serializedName: 'type', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
location: { | ||
required: false, | ||
serializedName: 'location', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
tags: { | ||
required: false, | ||
serializedName: 'tags', | ||
type: { | ||
name: 'Dictionary', | ||
value: { | ||
required: false, | ||
serializedName: 'StringElementType', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
}, | ||
properties: { | ||
required: false, | ||
serializedName: 'properties', | ||
type: { | ||
name: 'Object' | ||
} | ||
} | ||
}, | ||
sku: { | ||
required: false, | ||
isConstant: true, | ||
serializedName: 'sku', | ||
defaultValue: {}, | ||
type: { | ||
name: 'Composite', | ||
className: 'AzureSku' | ||
} | ||
}, | ||
properties: { | ||
required: false, | ||
serializedName: 'properties', | ||
type: { | ||
name: 'Object' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = WorkspaceCollection; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,34 +19,36 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [keyName] Key name. Possible values include: 'key1', 'key2' | ||
* | ||
* | ||
*/ | ||
function WorkspaceCollectionAccessKey() { | ||
} | ||
class WorkspaceCollectionAccessKey { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of WorkspaceCollectionAccessKey | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionAccessKey | ||
* | ||
*/ | ||
WorkspaceCollectionAccessKey.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionAccessKey', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionAccessKey', | ||
modelProperties: { | ||
keyName: { | ||
required: false, | ||
serializedName: 'keyName', | ||
type: { | ||
name: 'Enum', | ||
allowedValues: [ 'key1', 'key2' ] | ||
/** | ||
* Defines the metadata of WorkspaceCollectionAccessKey | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionAccessKey | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionAccessKey', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionAccessKey', | ||
modelProperties: { | ||
keyName: { | ||
required: false, | ||
serializedName: 'keyName', | ||
type: { | ||
name: 'Enum', | ||
allowedValues: [ 'key1', 'key2' ] | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = WorkspaceCollectionAccessKey; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -19,42 +19,44 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
* @member {string} [key1] Access key 1 | ||
* | ||
* | ||
* @member {string} [key2] Access key 2 | ||
* | ||
* | ||
*/ | ||
function WorkspaceCollectionAccessKeys() { | ||
} | ||
class WorkspaceCollectionAccessKeys { | ||
constructor() { | ||
} | ||
/** | ||
* Defines the metadata of WorkspaceCollectionAccessKeys | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionAccessKeys | ||
* | ||
*/ | ||
WorkspaceCollectionAccessKeys.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionAccessKeys', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionAccessKeys', | ||
modelProperties: { | ||
key1: { | ||
required: false, | ||
serializedName: 'key1', | ||
type: { | ||
name: 'String' | ||
/** | ||
* Defines the metadata of WorkspaceCollectionAccessKeys | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionAccessKeys | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionAccessKeys', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionAccessKeys', | ||
modelProperties: { | ||
key1: { | ||
required: false, | ||
serializedName: 'key1', | ||
type: { | ||
name: 'String' | ||
} | ||
}, | ||
key2: { | ||
required: false, | ||
serializedName: 'key2', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
}, | ||
key2: { | ||
required: false, | ||
serializedName: 'key2', | ||
type: { | ||
name: 'String' | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = WorkspaceCollectionAccessKeys; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,4 +14,2 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var util = require('util'); | ||
/** | ||
@@ -21,36 +19,35 @@ * @class | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
*/ | ||
function WorkspaceCollectionList() { | ||
} | ||
class WorkspaceCollectionList extends Array { | ||
constructor() { | ||
super(); | ||
} | ||
util.inherits(WorkspaceCollectionList, Array); | ||
/** | ||
* Defines the metadata of WorkspaceCollectionList | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionList | ||
* | ||
*/ | ||
WorkspaceCollectionList.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionList', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: '', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollection' | ||
} | ||
/** | ||
* Defines the metadata of WorkspaceCollectionList | ||
* | ||
* @returns {object} metadata of WorkspaceCollectionList | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionList', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollectionList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: '', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'WorkspaceCollectionElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceCollection' | ||
} | ||
} | ||
} | ||
@@ -60,6 +57,6 @@ } | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = WorkspaceCollectionList; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,4 +14,2 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var util = require('util'); | ||
/** | ||
@@ -21,36 +19,35 @@ * @class | ||
* @constructor | ||
* @member {array} [value] | ||
* | ||
*/ | ||
function WorkspaceList() { | ||
} | ||
class WorkspaceList extends Array { | ||
constructor() { | ||
super(); | ||
} | ||
util.inherits(WorkspaceList, Array); | ||
/** | ||
* Defines the metadata of WorkspaceList | ||
* | ||
* @returns {object} metadata of WorkspaceList | ||
* | ||
*/ | ||
WorkspaceList.prototype.mapper = function () { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceList', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: '', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'WorkspaceElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'Workspace' | ||
} | ||
/** | ||
* Defines the metadata of WorkspaceList | ||
* | ||
* @returns {object} metadata of WorkspaceList | ||
* | ||
*/ | ||
mapper() { | ||
return { | ||
required: false, | ||
serializedName: 'WorkspaceList', | ||
type: { | ||
name: 'Composite', | ||
className: 'WorkspaceList', | ||
modelProperties: { | ||
value: { | ||
required: false, | ||
serializedName: '', | ||
type: { | ||
name: 'Sequence', | ||
element: { | ||
required: false, | ||
serializedName: 'WorkspaceElementType', | ||
type: { | ||
name: 'Composite', | ||
className: 'Workspace' | ||
} | ||
} | ||
} | ||
@@ -60,6 +57,6 @@ } | ||
} | ||
} | ||
}; | ||
}; | ||
}; | ||
} | ||
} | ||
module.exports = WorkspaceList; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -12,3 +12,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
import { ServiceClientOptions, RequestOptions, ServiceCallback } from 'ms-rest'; | ||
import { ServiceClientOptions, RequestOptions, ServiceCallback, HttpOperationResponse } from 'ms-rest'; | ||
import * as models from '../models'; | ||
@@ -25,2 +25,3 @@ | ||
/** | ||
@@ -30,45 +31,136 @@ * Retrieves an existing Power BI Workspace Collection. | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollection>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
getByNameWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollection>>; | ||
/** | ||
* Retrieves an existing Power BI Workspace Collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollection} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollection} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollection} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
getByName(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollection>; | ||
getByName(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
getByName(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
getByName(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
/** | ||
* Creates a new Power BI Workspace Collection with the specified properties. | ||
* A Power BI Workspace Collection contains one or more Power BI Workspaces | ||
* and can be used to provision keys that provide API access to those Power | ||
* BI Workspaces. | ||
* Creates a new Power BI Workspace Collection with the specified properties. A | ||
* Power BI Workspace Collection contains one or more workspaces, and can be | ||
* used to provision keys that provide API access to those workspaces. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Create workspace collection request | ||
* | ||
* | ||
* @param {string} [body.location] Azure location | ||
* | ||
* | ||
* @param {object} [body.tags] | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollection>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
createWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, body: models.CreateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollection>>; | ||
/** | ||
* Creates a new Power BI Workspace Collection with the specified properties. A | ||
* Power BI Workspace Collection contains one or more workspaces, and can be | ||
* used to provision keys that provide API access to those workspaces. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Create workspace collection request | ||
* | ||
* @param {string} [body.location] Azure location | ||
* | ||
* @param {object} [body.tags] | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollection} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollection} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollection} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
create(resourceGroupName: string, workspaceCollectionName: string, body: models.CreateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollection>; | ||
create(resourceGroupName: string, workspaceCollectionName: string, body: models.CreateWorkspaceCollectionRequest, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
create(resourceGroupName: string, workspaceCollectionName: string, body: models.CreateWorkspaceCollectionRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
create(resourceGroupName: string, workspaceCollectionName: string, body: models.CreateWorkspaceCollectionRequest, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
/** | ||
@@ -79,21 +171,68 @@ * Update an existing Power BI Workspace Collection with the specified | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Update workspace collection request | ||
* | ||
* | ||
* @param {object} [body.tags] | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollection>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
updateWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, body: models.UpdateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollection>>; | ||
/** | ||
* Update an existing Power BI Workspace Collection with the specified | ||
* properties. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Update workspace collection request | ||
* | ||
* @param {object} [body.tags] | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollection} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollection} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollection} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
update(resourceGroupName: string, workspaceCollectionName: string, body: models.UpdateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollection>; | ||
update(resourceGroupName: string, workspaceCollectionName: string, body: models.UpdateWorkspaceCollectionRequest, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
update(resourceGroupName: string, workspaceCollectionName: string, body: models.UpdateWorkspaceCollectionRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
update(resourceGroupName: string, workspaceCollectionName: string, body: models.UpdateWorkspaceCollectionRequest, callback: ServiceCallback<models.WorkspaceCollection>): void; | ||
/** | ||
@@ -103,16 +242,18 @@ * Delete a Power BI Workspace Collection. | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<null>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
deleteMethod(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void; | ||
deleteMethod(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<void>): void; | ||
deleteMethodWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<void>>; | ||
@@ -123,72 +264,218 @@ /** | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {null} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {null} [result] - The deserialized result object if an error did not occur. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
beginDeleteMethod(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void; | ||
beginDeleteMethod(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<void>): void; | ||
deleteMethod(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<void>; | ||
deleteMethod(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<void>): void; | ||
deleteMethod(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void; | ||
/** | ||
* Check that the specified Power BI Workspace Collection name is valid and | ||
* not in use. | ||
* Verify the specified Power BI Workspace Collection name is valid and not | ||
* already in use. | ||
* | ||
* @param {string} location Azure location | ||
* | ||
* | ||
* @param {object} body Check name availability request | ||
* | ||
* | ||
* @param {string} [body.name] Workspace collection name | ||
* | ||
* | ||
* @param {string} [body.type] Resource type | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<CheckNameResponse>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
checkNameAvailabilityWithHttpOperationResponse(location: string, body: models.CheckNameRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.CheckNameResponse>>; | ||
/** | ||
* Verify the specified Power BI Workspace Collection name is valid and not | ||
* already in use. | ||
* | ||
* @param {string} location Azure location | ||
* | ||
* @param {object} body Check name availability request | ||
* | ||
* @param {string} [body.name] Workspace collection name | ||
* | ||
* @param {string} [body.type] Resource type | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {CheckNameResponse} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {CheckNameResponse} [result] - The deserialized result object if an error did not occur. | ||
* See {@link CheckNameResponse} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
checkNameAvailability(location: string, body: models.CheckNameRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.CheckNameResponse>; | ||
checkNameAvailability(location: string, body: models.CheckNameRequest, callback: ServiceCallback<models.CheckNameResponse>): void; | ||
checkNameAvailability(location: string, body: models.CheckNameRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.CheckNameResponse>): void; | ||
checkNameAvailability(location: string, body: models.CheckNameRequest, callback: ServiceCallback<models.CheckNameResponse>): void; | ||
/** | ||
* Retrieves all existing Power BI Workspace Collections in the specified | ||
* Retrieves all existing Power BI workspace collections in the specified | ||
* resource group. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollectionList>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
listByResourceGroupWithHttpOperationResponse(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollectionList>>; | ||
/** | ||
* Retrieves all existing Power BI workspace collections in the specified | ||
* resource group. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollectionList} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollectionList} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollectionList} for more | ||
* information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
listByResourceGroup(resourceGroupName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollectionList>; | ||
listByResourceGroup(resourceGroupName: string, callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
listByResourceGroup(resourceGroupName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
listByResourceGroup(resourceGroupName: string, callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
/** | ||
* Retrieves all existing Power BI Workspace Collections in the specified | ||
* Retrieves all existing Power BI workspace collections in the specified | ||
* subscription. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollectionList>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
listBySubscriptionWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollectionList>>; | ||
/** | ||
* Retrieves all existing Power BI workspace collections in the specified | ||
* subscription. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollectionList} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollectionList} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollectionList} for more | ||
* information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
listBySubscription(options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollectionList>; | ||
listBySubscription(callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
listBySubscription(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
listBySubscription(callback: ServiceCallback<models.WorkspaceCollectionList>): void; | ||
/** | ||
@@ -199,17 +486,61 @@ * Retrieves the primary and secondary access keys for the specified Power BI | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollectionAccessKeys>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
getAccessKeysWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollectionAccessKeys>>; | ||
/** | ||
* Retrieves the primary and secondary access keys for the specified Power BI | ||
* Workspace Collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollectionAccessKeys} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollectionAccessKeys} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollectionAccessKeys} for more | ||
* information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
getAccessKeys(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollectionAccessKeys>; | ||
getAccessKeys(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
getAccessKeys(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
getAccessKeys(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
/** | ||
@@ -220,22 +551,71 @@ * Regenerates the primary or secondary access key for the specified Power BI | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Access key to regenerate | ||
* | ||
* | ||
* @param {string} [body.keyName] Key name. Possible values include: 'key1', | ||
* 'key2' | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceCollectionAccessKeys>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
regenerateKeyWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, body: models.WorkspaceCollectionAccessKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceCollectionAccessKeys>>; | ||
/** | ||
* Regenerates the primary or secondary access key for the specified Power BI | ||
* Workspace Collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} body Access key to regenerate | ||
* | ||
* @param {string} [body.keyName] Key name. Possible values include: 'key1', | ||
* 'key2' | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceCollectionAccessKeys} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceCollectionAccessKeys} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceCollectionAccessKeys} for more | ||
* information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
regenerateKey(resourceGroupName: string, workspaceCollectionName: string, body: models.WorkspaceCollectionAccessKey, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceCollectionAccessKeys>; | ||
regenerateKey(resourceGroupName: string, workspaceCollectionName: string, body: models.WorkspaceCollectionAccessKey, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
regenerateKey(resourceGroupName: string, workspaceCollectionName: string, body: models.WorkspaceCollectionAccessKey, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
regenerateKey(resourceGroupName: string, workspaceCollectionName: string, body: models.WorkspaceCollectionAccessKey, callback: ServiceCallback<models.WorkspaceCollectionAccessKeys>): void; | ||
/** | ||
@@ -246,20 +626,125 @@ * Migrates an existing Power BI Workspace Collection to a different resource | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* | ||
* @param {object} body Workspace migration request | ||
* | ||
* @param {string} [body.targetResourceGroup] Name of the resource group that | ||
* the Power BI Workspace Collections will be migrated to. | ||
* | ||
* | ||
* @param {string} [body.targetResourceGroup] Name of the resource group the | ||
* Power BI workspace collections will be migrated to. | ||
* | ||
* @param {array} [body.resources] | ||
* | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<null>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
migrateWithHttpOperationResponse(resourceGroupName: string, body: models.MigrateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<void>>; | ||
/** | ||
* Migrates an existing Power BI Workspace Collection to a different resource | ||
* group and/or subscription. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {object} body Workspace migration request | ||
* | ||
* @param {string} [body.targetResourceGroup] Name of the resource group the | ||
* Power BI workspace collections will be migrated to. | ||
* | ||
* @param {array} [body.resources] | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {null} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {null} [result] - The deserialized result object if an error did not occur. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
migrate(resourceGroupName: string, body: models.MigrateWorkspaceCollectionRequest, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<void>; | ||
migrate(resourceGroupName: string, body: models.MigrateWorkspaceCollectionRequest, callback: ServiceCallback<void>): void; | ||
migrate(resourceGroupName: string, body: models.MigrateWorkspaceCollectionRequest, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void; | ||
migrate(resourceGroupName: string, body: models.MigrateWorkspaceCollectionRequest, callback: ServiceCallback<void>): void; | ||
/** | ||
* Delete a Power BI Workspace Collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<null>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
beginDeleteMethodWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<void>>; | ||
/** | ||
* Delete a Power BI Workspace Collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {null} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {null} [result] - The deserialized result object if an error did not occur. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
beginDeleteMethod(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<void>; | ||
beginDeleteMethod(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<void>): void; | ||
beginDeleteMethod(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<void>): void; | ||
} | ||
@@ -275,21 +760,64 @@ | ||
/** | ||
* Retrieves all existing Power BI Workspaces in the specified Workspace | ||
* Collection. | ||
* Retrieves all existing Power BI workspaces in the specified workspace | ||
* collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceList>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
listWithHttpOperationResponse(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.WorkspaceList>>; | ||
/** | ||
* Retrieves all existing Power BI workspaces in the specified workspace | ||
* collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {WorkspaceList} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {WorkspaceList} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceList} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
list(resourceGroupName: string, workspaceCollectionName: string, options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.WorkspaceList>; | ||
list(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceList>): void; | ||
list(resourceGroupName: string, workspaceCollectionName: string, options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.WorkspaceList>): void; | ||
list(resourceGroupName: string, workspaceCollectionName: string, callback: ServiceCallback<models.WorkspaceList>): void; | ||
} |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -8,0 +8,0 @@ * Changes may cause incorrect behavior and will be lost if the code is |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -14,37 +14,22 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var util = require('util'); | ||
var msRest = require('ms-rest'); | ||
var msRestAzure = require('ms-rest-azure'); | ||
var WebResource = msRest.WebResource; | ||
const msRest = require('ms-rest'); | ||
const msRestAzure = require('ms-rest-azure'); | ||
const WebResource = msRest.WebResource; | ||
/** | ||
* @class | ||
* Workspaces | ||
* __NOTE__: An instance of this class is automatically created for an | ||
* instance of the PowerBIEmbeddedManagementClient. | ||
* Initializes a new instance of the Workspaces class. | ||
* @constructor | ||
* Retrieves all existing Power BI workspaces in the specified workspace | ||
* collection. | ||
* | ||
* @param {PowerBIEmbeddedManagementClient} client Reference to the service client. | ||
*/ | ||
function Workspaces(client) { | ||
this.client = client; | ||
} | ||
/** | ||
* Retrieves all existing Power BI Workspaces in the specified Workspace | ||
* Collection. | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded workspace | ||
* collection name | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {function} callback | ||
* | ||
* @param {function} callback - The callback. | ||
* | ||
* @returns {function} callback(err, result, request, response) | ||
@@ -54,3 +39,3 @@ * | ||
* | ||
* {object} [result] - The deserialized result object. | ||
* {object} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceList} for more information. | ||
@@ -62,4 +47,5 @@ * | ||
*/ | ||
Workspaces.prototype.list = function (resourceGroupName, workspaceCollectionName, options, callback) { | ||
var client = this.client; | ||
function _list(resourceGroupName, workspaceCollectionName, options, callback) { | ||
/* jshint validthis: true */ | ||
let client = this.client; | ||
if(!callback && typeof options === 'function') { | ||
@@ -94,8 +80,8 @@ callback = options; | ||
// Construct URL | ||
var requestUrl = this.client.baseUri + | ||
'//subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.PowerBI/workspaceCollections/{workspaceCollectionName}/workspaces'; | ||
let baseUrl = this.client.baseUri; | ||
let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.PowerBI/workspaceCollections/{workspaceCollectionName}/workspaces'; | ||
requestUrl = requestUrl.replace('{subscriptionId}', encodeURIComponent(this.client.subscriptionId)); | ||
requestUrl = requestUrl.replace('{resourceGroupName}', encodeURIComponent(resourceGroupName)); | ||
requestUrl = requestUrl.replace('{workspaceCollectionName}', encodeURIComponent(workspaceCollectionName)); | ||
var queryParameters = []; | ||
let queryParameters = []; | ||
queryParameters.push('api-version=' + encodeURIComponent(this.client.apiVersion)); | ||
@@ -105,8 +91,5 @@ if (queryParameters.length > 0) { | ||
} | ||
// trim all duplicate forward slashes in the url | ||
var regex = /([^:]\/)\/+/gi; | ||
requestUrl = requestUrl.replace(regex, '$1'); | ||
// Create HTTP transport objects | ||
var httpRequest = new WebResource(); | ||
let httpRequest = new WebResource(); | ||
httpRequest.method = 'GET'; | ||
@@ -123,3 +106,3 @@ httpRequest.headers = {}; | ||
if(options) { | ||
for(var headerName in options['customHeaders']) { | ||
for(let headerName in options['customHeaders']) { | ||
if (options['customHeaders'].hasOwnProperty(headerName)) { | ||
@@ -133,9 +116,9 @@ httpRequest.headers[headerName] = options['customHeaders'][headerName]; | ||
// Send Request | ||
return client.pipeline(httpRequest, function (err, response, responseBody) { | ||
return client.pipeline(httpRequest, (err, response, responseBody) => { | ||
if (err) { | ||
return callback(err); | ||
} | ||
var statusCode = response.statusCode; | ||
let statusCode = response.statusCode; | ||
if (statusCode !== 200) { | ||
var error = new Error(responseBody); | ||
let error = new Error(responseBody); | ||
error.statusCode = response.statusCode; | ||
@@ -145,17 +128,18 @@ error.request = msRest.stripRequest(httpRequest); | ||
if (responseBody === '') responseBody = null; | ||
var parsedErrorResponse; | ||
let parsedErrorResponse; | ||
try { | ||
parsedErrorResponse = JSON.parse(responseBody); | ||
if (parsedErrorResponse) { | ||
if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; | ||
if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; | ||
if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; | ||
let internalError = null; | ||
if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; | ||
error.code = internalError ? internalError.code : parsedErrorResponse.code; | ||
error.message = internalError ? internalError.message : parsedErrorResponse.message; | ||
} | ||
if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { | ||
var resultMapper = new client.models['ErrorModel']().mapper(); | ||
let resultMapper = new client.models['ErrorModel']().mapper(); | ||
error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); | ||
} | ||
} catch (defaultError) { | ||
error.message = util.format('Error "%s" occurred in deserializing the responseBody ' + | ||
'- "%s" for the default response.', defaultError.message, responseBody); | ||
error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + | ||
`- "${responseBody}" for the default response.`; | ||
return callback(error); | ||
@@ -166,7 +150,7 @@ } | ||
// Create Result | ||
var result = null; | ||
let result = null; | ||
if (responseBody === '') responseBody = null; | ||
// Deserialize Response | ||
if (statusCode === 200) { | ||
var parsedResponse = null; | ||
let parsedResponse = null; | ||
try { | ||
@@ -176,7 +160,7 @@ parsedResponse = JSON.parse(responseBody); | ||
if (parsedResponse !== null && parsedResponse !== undefined) { | ||
var resultMapper = new client.models['WorkspaceList']().mapper(); | ||
let resultMapper = new client.models['WorkspaceList']().mapper(); | ||
result = client.deserialize(resultMapper, parsedResponse, 'result'); | ||
} | ||
} catch (error) { | ||
var deserializationError = new Error(util.format('Error "%s" occurred in deserializing the responseBody - "%s"', error, responseBody)); | ||
let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); | ||
deserializationError.request = msRest.stripRequest(httpRequest); | ||
@@ -190,5 +174,112 @@ deserializationError.response = msRest.stripResponse(response); | ||
}); | ||
}; | ||
} | ||
/** | ||
* @class | ||
* Workspaces | ||
* __NOTE__: An instance of this class is automatically created for an | ||
* instance of the PowerBIEmbeddedManagementClient. | ||
* Initializes a new instance of the Workspaces class. | ||
* @constructor | ||
* | ||
* @param {PowerBIEmbeddedManagementClient} client Reference to the service client. | ||
*/ | ||
class Workspaces { | ||
constructor(client) { | ||
this.client = client; | ||
this._list = _list; | ||
} | ||
/** | ||
* Retrieves all existing Power BI workspaces in the specified workspace | ||
* collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<WorkspaceList>} - The deserialized result object. | ||
* | ||
* @reject {Error} - The error object. | ||
*/ | ||
listWithHttpOperationResponse(resourceGroupName, workspaceCollectionName, options) { | ||
let client = this.client; | ||
let self = this; | ||
return new Promise((resolve, reject) => { | ||
self._list(resourceGroupName, workspaceCollectionName, options, (err, result, request, response) => { | ||
let httpOperationResponse = new msRest.HttpOperationResponse(request, response); | ||
httpOperationResponse.body = result; | ||
if (err) { reject(err); } | ||
else { resolve(httpOperationResponse); } | ||
return; | ||
}); | ||
}); | ||
} | ||
/** | ||
* Retrieves all existing Power BI workspaces in the specified workspace | ||
* collection. | ||
* | ||
* @param {string} resourceGroupName Azure resource group | ||
* | ||
* @param {string} workspaceCollectionName Power BI Embedded Workspace | ||
* Collection name | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {function} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {function|Promise} If a callback was passed as the last parameter | ||
* then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned | ||
* | ||
* @resolve {WorkspaceList} - The deserialized result object. | ||
* | ||
* @reject {Error} - The error object. | ||
* | ||
* {function} optionalCallback(err, result, request, response) | ||
* | ||
* {Error} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {object} [result] - The deserialized result object if an error did not occur. | ||
* See {@link WorkspaceList} for more information. | ||
* | ||
* {object} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {stream} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
list(resourceGroupName, workspaceCollectionName, options, optionalCallback) { | ||
let client = this.client; | ||
let self = this; | ||
if (!optionalCallback && typeof options === 'function') { | ||
optionalCallback = options; | ||
options = null; | ||
} | ||
if (!optionalCallback) { | ||
return new Promise((resolve, reject) => { | ||
self._list(resourceGroupName, workspaceCollectionName, options, (err, result, request, response) => { | ||
if (err) { reject(err); } | ||
else { resolve(result); } | ||
return; | ||
}); | ||
}); | ||
} else { | ||
return self._list(resourceGroupName, workspaceCollectionName, options, optionalCallback); | ||
} | ||
} | ||
} | ||
module.exports = Workspaces; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -12,3 +12,3 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
import { ServiceClientOptions, RequestOptions, ServiceCallback, ServiceClientCredentials } from 'ms-rest'; | ||
import { ServiceClientOptions, RequestOptions, ServiceCallback, HttpOperationResponse, ServiceClientCredentials } from 'ms-rest'; | ||
import * as models from "./models"; | ||
@@ -18,65 +18,103 @@ import * as operations from "./operations"; | ||
declare class PowerBIEmbeddedManagementClient { | ||
/** | ||
* @class | ||
* Initializes a new instance of the PowerBIEmbeddedManagementClient class. | ||
* @constructor | ||
* | ||
* @param {credentials} credentials - Gets Azure subscription credentials. | ||
* | ||
* @param {string} subscriptionId - Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. | ||
* | ||
* @param {string} [baseUri] - The base URI of the service. | ||
* | ||
* @param {object} [options] - The parameter options | ||
* | ||
* @param {Array} [options.filters] - Filters to be added to the request pipeline | ||
* | ||
* @param {object} [options.requestOptions] - Options for the underlying request object | ||
* {@link https://github.com/request/request#requestoptions-callback Options doc} | ||
* | ||
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy | ||
* | ||
* @param {string} [options.apiVersion] - Client Api Version. | ||
* | ||
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response. | ||
* | ||
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. | ||
* | ||
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. | ||
* | ||
*/ | ||
constructor(credentials: ServiceClientCredentials, subscriptionId: string, baseUri: string, options: ServiceClientOptions); | ||
/** | ||
* Initializes a new instance of the PowerBIEmbeddedManagementClient class. | ||
* @constructor | ||
* | ||
* @class | ||
* @param {credentials} credentials - Credentials needed for the client to connect to Azure. | ||
* | ||
* @param {string} subscriptionId - Gets subscription credentials which uniquely identify a Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. | ||
* | ||
* @param {string} [baseUri] - The base URI of the service. | ||
* | ||
* @param {object} [options] - The parameter options | ||
* | ||
* @param {Array} [options.filters] - Filters to be added to the request pipeline | ||
* | ||
* @param {object} [options.requestOptions] - Options for the underlying request object | ||
* {@link https://github.com/request/request#requestoptions-callback Options doc} | ||
* | ||
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy | ||
* | ||
* @param {string} [options.apiVersion] - Client Api Version. | ||
* | ||
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response. | ||
* | ||
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. | ||
* | ||
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. | ||
* | ||
*/ | ||
constructor(credentials: ServiceClientCredentials, subscriptionId: string, baseUri?: string, options?: ServiceClientOptions); | ||
credentials: ServiceClientCredentials; | ||
credentials: ServiceClientCredentials; | ||
subscriptionId: string; | ||
subscriptionId: string; | ||
apiVersion: string; | ||
apiVersion: string; | ||
acceptLanguage: string; | ||
acceptLanguage: string; | ||
longRunningOperationRetryTimeout: number; | ||
longRunningOperationRetryTimeout: number; | ||
generateClientRequestId: boolean; | ||
generateClientRequestId: boolean; | ||
// Operation groups | ||
workspaceCollections: operations.WorkspaceCollections; | ||
workspaces: operations.Workspaces; | ||
// Operation groups | ||
workspaceCollections: operations.WorkspaceCollections; | ||
workspaces: operations.Workspaces; | ||
/** | ||
* Indicates which operations can be performed by the Power BI Resource | ||
* Provider. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [callback] callback function; see ServiceCallback | ||
* doc in ms-rest index.d.ts for details | ||
*/ | ||
getAvailableOperations(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.OperationList>): void; | ||
getAvailableOperations(callback: ServiceCallback<models.OperationList>): void; | ||
/** | ||
* Indicates which operations can be performed by the Power BI Resource | ||
* Provider. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<OperationList>} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
*/ | ||
getAvailableOperationsWithHttpOperationResponse(options?: { customHeaders? : { [headerName: string]: string; } }): Promise<HttpOperationResponse<models.OperationList>>; | ||
/** | ||
* Indicates which operations can be performed by the Power BI Resource | ||
* Provider. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {ServiceCallback} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {ServiceCallback|Promise} If a callback was passed as the last | ||
* parameter then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned. | ||
* | ||
* @resolve {OperationList} - The deserialized result object. | ||
* | ||
* @reject {Error|ServiceError} - The error object. | ||
* | ||
* {ServiceCallback} optionalCallback(err, result, request, response) | ||
* | ||
* {Error|ServiceError} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {OperationList} [result] - The deserialized result object if an error did not occur. | ||
* See {@link OperationList} for more information. | ||
* | ||
* {WebResource} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {http.IncomingMessage} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
getAvailableOperations(options?: { customHeaders? : { [headerName: string]: string; } }): Promise<models.OperationList>; | ||
getAvailableOperations(callback: ServiceCallback<models.OperationList>): void; | ||
getAvailableOperations(options: { customHeaders? : { [headerName: string]: string; } }, callback: ServiceCallback<models.OperationList>): void; | ||
} | ||
export = PowerBIEmbeddedManagementClient; |
@@ -5,3 +5,3 @@ /* | ||
* license information. | ||
* | ||
* | ||
* Code generated by Microsoft (R) AutoRest Code Generator. | ||
@@ -18,82 +18,11 @@ * Changes may cause incorrect behavior and will be lost if the code is | ||
var util = require('util'); | ||
var msRest = require('ms-rest'); | ||
var msRestAzure = require('ms-rest-azure'); | ||
var ServiceClient = msRestAzure.AzureServiceClient; | ||
var WebResource = msRest.WebResource; | ||
const msRest = require('ms-rest'); | ||
const msRestAzure = require('ms-rest-azure'); | ||
const ServiceClient = msRestAzure.AzureServiceClient; | ||
const WebResource = msRest.WebResource; | ||
var models = require('./models'); | ||
var operations = require('./operations'); | ||
const models = require('./models'); | ||
const operations = require('./operations'); | ||
/** | ||
* @class | ||
* Initializes a new instance of the PowerBIEmbeddedManagementClient class. | ||
* @constructor | ||
* | ||
* @param {credentials} credentials - Gets Azure subscription credentials. | ||
* | ||
* @param {string} subscriptionId - Gets subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. | ||
* | ||
* @param {string} [baseUri] - The base URI of the service. | ||
* | ||
* @param {object} [options] - The parameter options | ||
* | ||
* @param {Array} [options.filters] - Filters to be added to the request pipeline | ||
* | ||
* @param {object} [options.requestOptions] - Options for the underlying request object | ||
* {@link https://github.com/request/request#requestoptions-callback Options doc} | ||
* | ||
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy | ||
* | ||
* @param {string} [options.apiVersion] - Client Api Version. | ||
* | ||
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response. | ||
* | ||
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. | ||
* | ||
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. | ||
* | ||
*/ | ||
function PowerBIEmbeddedManagementClient(credentials, subscriptionId, baseUri, options) { | ||
this.apiVersion = '2016-01-29'; | ||
this.acceptLanguage = 'en-US'; | ||
this.longRunningOperationRetryTimeout = 30; | ||
this.generateClientRequestId = true; | ||
if (credentials === null || credentials === undefined) { | ||
throw new Error('\'credentials\' cannot be null.'); | ||
} | ||
if (subscriptionId === null || subscriptionId === undefined) { | ||
throw new Error('\'subscriptionId\' cannot be null.'); | ||
} | ||
if (!options) options = {}; | ||
PowerBIEmbeddedManagementClient['super_'].call(this, credentials, options); | ||
this.baseUri = baseUri; | ||
if (!this.baseUri) { | ||
this.baseUri = 'https://management.azure.com'; | ||
} | ||
this.credentials = credentials; | ||
this.subscriptionId = subscriptionId; | ||
if(options.apiVersion !== null && options.apiVersion !== undefined) { | ||
this.apiVersion = options.apiVersion; | ||
} | ||
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) { | ||
this.acceptLanguage = options.acceptLanguage; | ||
} | ||
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { | ||
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout; | ||
} | ||
if(options.generateClientRequestId !== null && options.generateClientRequestId !== undefined) { | ||
this.generateClientRequestId = options.generateClientRequestId; | ||
} | ||
this.workspaceCollections = new operations.WorkspaceCollections(this); | ||
this.workspaces = new operations.Workspaces(this); | ||
this.models = models; | ||
msRest.addSerializationMixin(this); | ||
} | ||
util.inherits(PowerBIEmbeddedManagementClient, ServiceClient); | ||
/** | ||
@@ -104,8 +33,8 @@ * Indicates which operations can be performed by the Power BI Resource | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {function} callback | ||
* | ||
* @param {function} callback - The callback. | ||
* | ||
* @returns {function} callback(err, result, request, response) | ||
@@ -115,3 +44,3 @@ * | ||
* | ||
* {object} [result] - The deserialized result object. | ||
* {object} [result] - The deserialized result object if an error did not occur. | ||
* See {@link OperationList} for more information. | ||
@@ -123,4 +52,5 @@ * | ||
*/ | ||
PowerBIEmbeddedManagementClient.prototype.getAvailableOperations = function (options, callback) { | ||
var client = this; | ||
function _getAvailableOperations(options, callback) { | ||
/* jshint validthis: true */ | ||
let client = this; | ||
if(!callback && typeof options === 'function') { | ||
@@ -146,5 +76,5 @@ callback = options; | ||
// Construct URL | ||
var requestUrl = this.baseUri + | ||
'//providers/Microsoft.PowerBI/operations'; | ||
var queryParameters = []; | ||
let baseUrl = this.baseUri; | ||
let requestUrl = baseUrl + (baseUrl.endsWith('/') ? '' : '/') + 'providers/Microsoft.PowerBI/operations'; | ||
let queryParameters = []; | ||
queryParameters.push('api-version=' + encodeURIComponent(this.apiVersion)); | ||
@@ -154,8 +84,5 @@ if (queryParameters.length > 0) { | ||
} | ||
// trim all duplicate forward slashes in the url | ||
var regex = /([^:]\/)\/+/gi; | ||
requestUrl = requestUrl.replace(regex, '$1'); | ||
// Create HTTP transport objects | ||
var httpRequest = new WebResource(); | ||
let httpRequest = new WebResource(); | ||
httpRequest.method = 'GET'; | ||
@@ -172,3 +99,3 @@ httpRequest.headers = {}; | ||
if(options) { | ||
for(var headerName in options['customHeaders']) { | ||
for(let headerName in options['customHeaders']) { | ||
if (options['customHeaders'].hasOwnProperty(headerName)) { | ||
@@ -182,9 +109,9 @@ httpRequest.headers[headerName] = options['customHeaders'][headerName]; | ||
// Send Request | ||
return client.pipeline(httpRequest, function (err, response, responseBody) { | ||
return client.pipeline(httpRequest, (err, response, responseBody) => { | ||
if (err) { | ||
return callback(err); | ||
} | ||
var statusCode = response.statusCode; | ||
let statusCode = response.statusCode; | ||
if (statusCode !== 200) { | ||
var error = new Error(responseBody); | ||
let error = new Error(responseBody); | ||
error.statusCode = response.statusCode; | ||
@@ -194,17 +121,18 @@ error.request = msRest.stripRequest(httpRequest); | ||
if (responseBody === '') responseBody = null; | ||
var parsedErrorResponse; | ||
let parsedErrorResponse; | ||
try { | ||
parsedErrorResponse = JSON.parse(responseBody); | ||
if (parsedErrorResponse) { | ||
if (parsedErrorResponse.error) parsedErrorResponse = parsedErrorResponse.error; | ||
if (parsedErrorResponse.code) error.code = parsedErrorResponse.code; | ||
if (parsedErrorResponse.message) error.message = parsedErrorResponse.message; | ||
let internalError = null; | ||
if (parsedErrorResponse.error) internalError = parsedErrorResponse.error; | ||
error.code = internalError ? internalError.code : parsedErrorResponse.code; | ||
error.message = internalError ? internalError.message : parsedErrorResponse.message; | ||
} | ||
if (parsedErrorResponse !== null && parsedErrorResponse !== undefined) { | ||
var resultMapper = new client.models['ErrorModel']().mapper(); | ||
let resultMapper = new client.models['ErrorModel']().mapper(); | ||
error.body = client.deserialize(resultMapper, parsedErrorResponse, 'error.body'); | ||
} | ||
} catch (defaultError) { | ||
error.message = util.format('Error "%s" occurred in deserializing the responseBody ' + | ||
'- "%s" for the default response.', defaultError.message, responseBody); | ||
error.message = `Error "${defaultError.message}" occurred in deserializing the responseBody ` + | ||
`- "${responseBody}" for the default response.`; | ||
return callback(error); | ||
@@ -215,7 +143,7 @@ } | ||
// Create Result | ||
var result = null; | ||
let result = null; | ||
if (responseBody === '') responseBody = null; | ||
// Deserialize Response | ||
if (statusCode === 200) { | ||
var parsedResponse = null; | ||
let parsedResponse = null; | ||
try { | ||
@@ -225,7 +153,7 @@ parsedResponse = JSON.parse(responseBody); | ||
if (parsedResponse !== null && parsedResponse !== undefined) { | ||
var resultMapper = new client.models['OperationList']().mapper(); | ||
let resultMapper = new client.models['OperationList']().mapper(); | ||
result = client.deserialize(resultMapper, parsedResponse, 'result'); | ||
} | ||
} catch (error) { | ||
var deserializationError = new Error(util.format('Error "%s" occurred in deserializing the responseBody - "%s"', error, responseBody)); | ||
let deserializationError = new Error(`Error ${error} occurred in deserializing the responseBody - ${responseBody}`); | ||
deserializationError.request = msRest.stripRequest(httpRequest); | ||
@@ -239,4 +167,160 @@ deserializationError.response = msRest.stripResponse(response); | ||
}); | ||
}; | ||
} | ||
/** | ||
* @class | ||
* Initializes a new instance of the PowerBIEmbeddedManagementClient class. | ||
* @constructor | ||
* | ||
* @param {credentials} credentials - Credentials needed for the client to connect to Azure. | ||
* | ||
* @param {string} subscriptionId - Gets subscription credentials which uniquely identify a Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. | ||
* | ||
* @param {string} [baseUri] - The base URI of the service. | ||
* | ||
* @param {object} [options] - The parameter options | ||
* | ||
* @param {Array} [options.filters] - Filters to be added to the request pipeline | ||
* | ||
* @param {object} [options.requestOptions] - Options for the underlying request object | ||
* {@link https://github.com/request/request#requestoptions-callback Options doc} | ||
* | ||
* @param {boolean} [options.noRetryPolicy] - If set to true, turn off default retry policy | ||
* | ||
* @param {string} [options.apiVersion] - Client Api Version. | ||
* | ||
* @param {string} [options.acceptLanguage] - Gets or sets the preferred language for the response. | ||
* | ||
* @param {number} [options.longRunningOperationRetryTimeout] - Gets or sets the retry timeout in seconds for Long Running Operations. Default value is 30. | ||
* | ||
* @param {boolean} [options.generateClientRequestId] - When set to true a unique x-ms-client-request-id value is generated and included in each request. Default is true. | ||
* | ||
*/ | ||
class PowerBIEmbeddedManagementClient extends ServiceClient { | ||
constructor(credentials, subscriptionId, baseUri, options) { | ||
if (credentials === null || credentials === undefined) { | ||
throw new Error('\'credentials\' cannot be null.'); | ||
} | ||
if (subscriptionId === null || subscriptionId === undefined) { | ||
throw new Error('\'subscriptionId\' cannot be null.'); | ||
} | ||
if (!options) options = {}; | ||
super(credentials, options); | ||
this.apiVersion = '2016-01-29'; | ||
this.acceptLanguage = 'en-US'; | ||
this.longRunningOperationRetryTimeout = 30; | ||
this.generateClientRequestId = true; | ||
this.baseUri = baseUri; | ||
if (!this.baseUri) { | ||
this.baseUri = 'https://management.azure.com'; | ||
} | ||
this.credentials = credentials; | ||
this.subscriptionId = subscriptionId; | ||
let packageInfo = this.getPackageJsonInfo(__dirname); | ||
this.addUserAgentInfo(`${packageInfo.name}/${packageInfo.version}`); | ||
if(options.apiVersion !== null && options.apiVersion !== undefined) { | ||
this.apiVersion = options.apiVersion; | ||
} | ||
if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) { | ||
this.acceptLanguage = options.acceptLanguage; | ||
} | ||
if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { | ||
this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout; | ||
} | ||
if(options.generateClientRequestId !== null && options.generateClientRequestId !== undefined) { | ||
this.generateClientRequestId = options.generateClientRequestId; | ||
} | ||
this.workspaceCollections = new operations.WorkspaceCollections(this); | ||
this.workspaces = new operations.Workspaces(this); | ||
this.models = models; | ||
this._getAvailableOperations = _getAvailableOperations; | ||
msRest.addSerializationMixin(this); | ||
} | ||
/** | ||
* Indicates which operations can be performed by the Power BI Resource | ||
* Provider. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @returns {Promise} A promise is returned | ||
* | ||
* @resolve {HttpOperationResponse<OperationList>} - The deserialized result object. | ||
* | ||
* @reject {Error} - The error object. | ||
*/ | ||
getAvailableOperationsWithHttpOperationResponse(options) { | ||
let client = this; | ||
let self = this; | ||
return new Promise((resolve, reject) => { | ||
self._getAvailableOperations(options, (err, result, request, response) => { | ||
let httpOperationResponse = new msRest.HttpOperationResponse(request, response); | ||
httpOperationResponse.body = result; | ||
if (err) { reject(err); } | ||
else { resolve(httpOperationResponse); } | ||
return; | ||
}); | ||
}); | ||
} | ||
/** | ||
* Indicates which operations can be performed by the Power BI Resource | ||
* Provider. | ||
* | ||
* @param {object} [options] Optional Parameters. | ||
* | ||
* @param {object} [options.customHeaders] Headers that will be added to the | ||
* request | ||
* | ||
* @param {function} [optionalCallback] - The optional callback. | ||
* | ||
* @returns {function|Promise} If a callback was passed as the last parameter | ||
* then it returns the callback else returns a Promise. | ||
* | ||
* {Promise} A promise is returned | ||
* | ||
* @resolve {OperationList} - The deserialized result object. | ||
* | ||
* @reject {Error} - The error object. | ||
* | ||
* {function} optionalCallback(err, result, request, response) | ||
* | ||
* {Error} err - The Error object if an error occurred, null otherwise. | ||
* | ||
* {object} [result] - The deserialized result object if an error did not occur. | ||
* See {@link OperationList} for more information. | ||
* | ||
* {object} [request] - The HTTP Request object if an error did not occur. | ||
* | ||
* {stream} [response] - The HTTP Response stream if an error did not occur. | ||
*/ | ||
getAvailableOperations(options, optionalCallback) { | ||
let client = this; | ||
let self = this; | ||
if (!optionalCallback && typeof options === 'function') { | ||
optionalCallback = options; | ||
options = null; | ||
} | ||
if (!optionalCallback) { | ||
return new Promise((resolve, reject) => { | ||
self._getAvailableOperations(options, (err, result, request, response) => { | ||
if (err) { reject(err); } | ||
else { resolve(result); } | ||
return; | ||
}); | ||
}); | ||
} else { | ||
return self._getAvailableOperations(options, optionalCallback); | ||
} | ||
} | ||
} | ||
module.exports = PowerBIEmbeddedManagementClient; |
The MIT License (MIT) | ||
Copyright (c) 2016 Microsoft | ||
Copyright (c) 2017 Microsoft | ||
@@ -5,0 +5,0 @@ Permission is hereby granted, free of charge, to any person obtaining a copy |
@@ -7,3 +7,3 @@ { | ||
], | ||
"version": "0.1.1", | ||
"version": "1.0.0-preview", | ||
"description": "Microsoft Azure Power BI Embedded Client Library for node", | ||
@@ -19,6 +19,7 @@ "tags": [ | ||
"main": "./lib/powerBIEmbeddedManagementClient.js", | ||
"licenses": "MIT", | ||
"types": "./lib/powerBIEmbeddedManagementClient.d.ts", | ||
"license": "MIT", | ||
"dependencies": { | ||
"ms-rest": "^1.14.0", | ||
"ms-rest-azure": "^1.14.0" | ||
"ms-rest": "^2.0.0", | ||
"ms-rest-azure": "^2.0.0" | ||
}, | ||
@@ -25,0 +26,0 @@ "homepage": "http://github.com/Azure/azure-sdk-for-node", |
@@ -0,0 +0,0 @@ # Microsoft Azure SDK for Node.js - Power BI Embedded |
Sorry, the diff of this file is too big to display
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
218360
5561
0
28
+ Added@xmldom/xmldom@0.8.10(transitive)
+ Addedadal-node@0.2.4(transitive)
+ Addedajv@6.12.3(transitive)
+ Addedasynckit@0.4.0(transitive)
+ Addedaws-sign2@0.7.0(transitive)
+ Addedaxios@0.21.4(transitive)
+ Addedcaseless@0.12.0(transitive)
+ Addedfast-deep-equal@3.1.3(transitive)
+ Addedfast-json-stable-stringify@2.1.0(transitive)
+ Addedfollow-redirects@1.15.9(transitive)
+ Addedform-data@2.3.3(transitive)
+ Addedhar-schema@2.0.0(transitive)
+ Addedhar-validator@5.1.5(transitive)
+ Addedhttp-signature@1.2.01.3.6(transitive)
+ Addedis-buffer@1.1.6(transitive)
+ Addedis-stream@1.1.0(transitive)
+ Addedjson-schema-traverse@0.4.1(transitive)
+ Addedjsprim@2.0.2(transitive)
+ Addedms-rest@2.5.6(transitive)
+ Addedms-rest-azure@2.6.2(transitive)
+ Addedoauth-sign@0.9.0(transitive)
+ Addedperformance-now@2.1.0(transitive)
+ Addedpsl@1.15.0(transitive)
+ Addedpunycode@2.3.1(transitive)
+ Addedqs@6.5.3(transitive)
+ Addedrequest@2.88.2(transitive)
+ Addedtough-cookie@2.5.0(transitive)
+ Addedtunnel@0.0.5(transitive)
+ Addedtunnel-agent@0.6.0(transitive)
+ Addeduri-js@4.4.1(transitive)
- Removed@types/node@8.10.66(transitive)
- Removedadal-node@0.1.28(transitive)
- Removedansi-regex@2.1.1(transitive)
- Removedansi-styles@2.2.1(transitive)
- Removedassert-plus@0.2.0(transitive)
- Removedasync@0.2.73.2.6(transitive)
- Removedaws-sign2@0.6.0(transitive)
- Removedazure-arm-resource@1.6.1-preview(transitive)
- Removedbl@1.1.2(transitive)
- Removedboom@2.10.1(transitive)
- Removedcaseless@0.11.0(transitive)
- Removedchalk@1.1.3(transitive)
- Removedcommander@2.20.3(transitive)
- Removedcore-util-is@1.0.3(transitive)
- Removedcryptiles@2.0.5(transitive)
- Removedescape-string-regexp@1.0.5(transitive)
- Removedform-data@1.0.1(transitive)
- Removedgenerate-function@2.3.1(transitive)
- Removedgenerate-object-property@1.2.0(transitive)
- Removedhar-validator@2.0.6(transitive)
- Removedhas-ansi@2.0.0(transitive)
- Removedhawk@3.1.3(transitive)
- Removedhoek@2.16.3(transitive)
- Removedhttp-signature@1.1.1(transitive)
- Removedinherits@2.0.4(transitive)
- Removedis-my-ip-valid@1.0.1(transitive)
- Removedis-my-json-valid@2.20.6(transitive)
- Removedis-property@1.0.2(transitive)
- Removedisarray@1.0.0(transitive)
- Removedjsonpointer@5.0.1(transitive)
- Removedms-rest@1.15.7(transitive)
- Removedms-rest-azure@1.15.7(transitive)
- Removednode-uuid@1.4.8(transitive)
- Removedoauth-sign@0.8.2(transitive)
- Removedpinkie@2.0.4(transitive)
- Removedpinkie-promise@2.0.1(transitive)
- Removedprocess-nextick-args@1.0.7(transitive)
- Removedpunycode@1.4.1(transitive)
- Removedqs@6.2.4(transitive)
- Removedreadable-stream@2.0.6(transitive)
- Removedrequest@2.74.0(transitive)
- Removedsntp@1.0.9(transitive)
- Removedstring_decoder@0.10.31(transitive)
- Removedstringstream@0.0.6(transitive)
- Removedstrip-ansi@3.0.1(transitive)
- Removedsupports-color@2.0.0(transitive)
- Removedtough-cookie@2.3.4(transitive)
- Removedtunnel@0.0.6(transitive)
- Removedtunnel-agent@0.4.3(transitive)
- Removedutil-deprecate@1.0.2(transitive)
- Removedxmldom@0.6.0(transitive)
- Removedxtend@4.0.2(transitive)
Updatedms-rest@^2.0.0
Updatedms-rest-azure@^2.0.0