msRestUserAgentPolicy.js 657 B

12345678910111213141516171819
  1. // Copyright (c) Microsoft Corporation. All rights reserved.
  2. // Licensed under the MIT License. See License.txt in the project root for license information.
  3. import * as os from "os";
  4. import { Constants } from "../util/constants";
  5. export function getDefaultUserAgentKey() {
  6. return Constants.HeaderConstants.USER_AGENT;
  7. }
  8. export function getPlatformSpecificData() {
  9. var runtimeInfo = {
  10. key: "Node",
  11. value: process.version
  12. };
  13. var osInfo = {
  14. key: "OS",
  15. value: "(" + os.arch() + "-" + os.type() + "-" + os.release() + ")"
  16. };
  17. return [runtimeInfo, osInfo];
  18. }
  19. //# sourceMappingURL=msRestUserAgentPolicy.js.map