UNPKG

appcenter-cli

Version:

Command line tool for Visual Studio App Center

57 lines (56 loc) 2.16 kB
"use strict"; /* * Copyright (c) Microsoft Corporation. * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.CodePushDeploymentUploadImpl = void 0; const coreClient = require("@azure/core-client"); const Mappers = require("../models/mappers"); const Parameters = require("../models/parameters"); /** Class containing CodePushDeploymentUpload operations. */ class CodePushDeploymentUploadImpl { /** * Initialize a new instance of the class CodePushDeploymentUpload class. * @param client Reference to the service client */ constructor(client) { this.client = client; } /** * Create a new CodePush release upload for the specified deployment * @param deploymentName deployment name * @param ownerName The name of the owner * @param appName The name of the application * @param options The options parameters. */ create(deploymentName, ownerName, appName, options) { return this.client.sendOperationRequest({ deploymentName, ownerName, appName, options }, createOperationSpec); } } exports.CodePushDeploymentUploadImpl = CodePushDeploymentUploadImpl; // Operation Specifications const serializer = coreClient.createSerializer(Mappers, /* isXml */ false); const createOperationSpec = { path: "/v0.1/apps/{owner_name}/{app_name}/deployments/{deployment_name}/uploads", httpMethod: "POST", responses: { 200: { bodyMapper: Mappers.Paths1Kb13FjV01AppsOwnerNameAppNameDeploymentsDeploymentNameUploadsPostResponses200ContentApplicationJsonSchema }, default: { bodyMapper: Mappers.PathsO9B77WV01AppsOwnerNameAppNameDeploymentsDeploymentNameUploadsPostResponsesDefaultContentApplicationJsonSchema } }, urlParameters: [ Parameters.$host, Parameters.ownerName, Parameters.appName, Parameters.deploymentName ], headerParameters: [Parameters.accept], serializer };