appcenter-cli
Version:
Command line tool for Visual Studio App Center
60 lines (59 loc) • 2.11 kB
JavaScript
;
/*
* 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.CommitsImpl = void 0;
const coreClient = require("@azure/core-client");
const Mappers = require("../models/mappers");
const Parameters = require("../models/parameters");
/** Class containing Commits operations. */
class CommitsImpl {
/**
* Initialize a new instance of the class Commits class.
* @param client Reference to the service client
*/
constructor(client) {
this.client = client;
}
/**
* Returns commit information for a batch of shas
* @param hashes A collection of commit SHAs comma-delimited
* @param ownerName The name of the owner
* @param appName The name of the application
* @param options The options parameters.
*/
listByShaList(hashes, ownerName, appName, options) {
return this.client.sendOperationRequest({ hashes, ownerName, appName, options }, listByShaListOperationSpec);
}
}
exports.CommitsImpl = CommitsImpl;
// Operation Specifications
const serializer = coreClient.createSerializer(Mappers, /* isXml */ false);
const listByShaListOperationSpec = {
path: "/v0.1/apps/{owner_name}/{app_name}/commits/batch",
httpMethod: "GET",
responses: {
200: {
bodyMapper: {
type: {
name: "Sequence",
element: {
type: {
name: "Composite",
className: "PathsCbr4BhV01AppsOwnerNameAppNameCommitsBatchGetResponses200ContentApplicationJsonSchemaItems"
}
}
}
}
}
},
queryParameters: [Parameters.hashes],
urlParameters: [Parameters.$host, Parameters.ownerName, Parameters.appName],
headerParameters: [Parameters.accept],
serializer
};