Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR apimanagement/resource-manager] [Hub Generated] Review request for Microsoft.ApiManagement to add version stable/2019-01-01 #2120

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/@azure/arm-apimanagement/LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2018 Microsoft
Copyright (c) 2019 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
31 changes: 18 additions & 13 deletions packages/@azure/arm-apimanagement/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ This package contains an isomorphic SDK for ApiManagementClient.

### How to Install

```
```bash
npm install @azure/arm-apimanagement
```

### How to use

#### nodejs - Authentication, client creation and listByService policy as an example written in TypeScript.
#### nodejs - Authentication, client creation and listByService api as an example written in TypeScript.

##### Install @azure/ms-rest-nodeauth

```
```bash
npm install @azure/ms-rest-nodeauth
```

##### Sample code

```ts
```typescript
import * as msRest from "@azure/ms-rest-js";
import * as msRestAzure from "@azure/ms-rest-azure-js";
import * as msRestNodeAuth from "@azure/ms-rest-nodeauth";
Expand All @@ -36,8 +36,12 @@ msRestNodeAuth.interactiveLogin().then((creds) => {
const client = new ApiManagementClient(creds, subscriptionId);
const resourceGroupName = "testresourceGroupName";
const serviceName = "testserviceName";
const scope = "Tenant";
client.policy.listByService(resourceGroupName, serviceName, scope).then((result) => {
const filter = "testfilter";
const top = 1;
const skip = 1;
const tags = "testtags";
const expandApiVersionSet = true;
client.api.listByService(resourceGroupName, serviceName, filter, top, skip, tags, expandApiVersionSet).then((result) => {
console.log("The result is:");
console.log(result);
});
Expand All @@ -46,11 +50,11 @@ msRestNodeAuth.interactiveLogin().then((creds) => {
});
```

#### browser - Authentication, client creation and listByService policy as an example written in JavaScript.
#### browser - Authentication, client creation and listByService api as an example written in JavaScript.

##### Install @azure/ms-rest-browserauth

```
```bash
npm install @azure/ms-rest-browserauth
```

Expand Down Expand Up @@ -82,8 +86,12 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
const client = new Azure.ArmApimanagement.ApiManagementClient(res.creds, subscriptionId);
const resourceGroupName = "testresourceGroupName";
const serviceName = "testserviceName";
const scope = "Tenant";
client.policy.listByService(resourceGroupName, serviceName, scope).then((result) => {
const filter = "testfilter";
const top = 1;
const skip = 1;
const tags = "testtags";
const expandApiVersionSet = true;
client.api.listByService(resourceGroupName, serviceName, filter, top, skip, tags, expandApiVersionSet).then((result) => {
console.log("The result is:");
console.log(result);
}).catch((err) => {
Expand All @@ -100,6 +108,3 @@ See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to
## Related projects

- [Microsoft Azure SDK for Javascript](https://github.com/Azure/azure-sdk-for-js)


![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js%2Fpackages%2F%40azure%2Farm-apimanagement%2FREADME.png)
48 changes: 26 additions & 22 deletions packages/@azure/arm-apimanagement/lib/apiManagementClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,39 +17,43 @@ import { ApiManagementClientContext } from "./apiManagementClientContext";

class ApiManagementClient extends ApiManagementClientContext {
// Operation groups
policy: operations.Policy;
policySnippets: operations.PolicySnippets;
regions: operations.Regions;
api: operations.Api;
apiRevisions: operations.ApiRevisions;
apiRevision: operations.ApiRevision;
apiRelease: operations.ApiRelease;
apiOperation: operations.ApiOperation;
apiOperationPolicy: operations.ApiOperationPolicy;
tag: operations.Tag;
apiProduct: operations.ApiProduct;
apiPolicy: operations.ApiPolicy;
apiSchema: operations.ApiSchema;
apiDiagnostic: operations.ApiDiagnostic;
apiDiagnosticLogger: operations.ApiDiagnosticLogger;
apiIssue: operations.ApiIssue;
apiIssueComment: operations.ApiIssueComment;
apiIssueAttachment: operations.ApiIssueAttachment;
apiTagDescription: operations.ApiTagDescription;
operation: operations.OperationOperations;
apiVersionSet: operations.ApiVersionSet;
authorizationServer: operations.AuthorizationServer;
backend: operations.Backend;
cache: operations.Cache;
certificate: operations.Certificate;
apiManagementOperations: operations.ApiManagementOperations;
apiManagementServiceSkus: operations.ApiManagementServiceSkus;
apiManagementService: operations.ApiManagementService;
diagnostic: operations.Diagnostic;
diagnosticLogger: operations.DiagnosticLogger;
emailTemplate: operations.EmailTemplate;
group: operations.Group;
groupUser: operations.GroupUser;
identityProvider: operations.IdentityProvider;
issue: operations.Issue;
logger: operations.Logger;
networkStatus: operations.NetworkStatus;
notification: operations.Notification;
notificationRecipientUser: operations.NotificationRecipientUser;
notificationRecipientEmail: operations.NotificationRecipientEmail;
networkStatus: operations.NetworkStatus;
openIdConnectProvider: operations.OpenIdConnectProvider;
policy: operations.Policy;
policySnippet: operations.PolicySnippet;
signInSettings: operations.SignInSettings;
signUpSettings: operations.SignUpSettings;
delegationSettings: operations.DelegationSettings;
Expand All @@ -61,20 +65,18 @@ class ApiManagementClient extends ApiManagementClientContext {
property: operations.Property;
quotaByCounterKeys: operations.QuotaByCounterKeys;
quotaByPeriodKeys: operations.QuotaByPeriodKeys;
region: operations.Region;
reports: operations.Reports;
subscription: operations.Subscription;
tagResource: operations.TagResource;
tag: operations.Tag;
tagDescription: operations.TagDescription;
operation: operations.OperationOperations;
tenantAccess: operations.TenantAccess;
tenantAccessGit: operations.TenantAccessGit;
tenantConfiguration: operations.TenantConfiguration;
user: operations.User;
userGroup: operations.UserGroup;
userSubscription: operations.UserSubscription;
userIdentities: operations.UserIdentities;
apiVersionSet: operations.ApiVersionSet;
userConfirmationPassword: operations.UserConfirmationPassword;
apiExport: operations.ApiExport;

/**
Expand All @@ -86,39 +88,43 @@ class ApiManagementClient extends ApiManagementClientContext {
*/
constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.ApiManagementClientOptions) {
super(credentials, subscriptionId, options);
this.policy = new operations.Policy(this);
this.policySnippets = new operations.PolicySnippets(this);
this.regions = new operations.Regions(this);
this.api = new operations.Api(this);
this.apiRevisions = new operations.ApiRevisions(this);
this.apiRevision = new operations.ApiRevision(this);
this.apiRelease = new operations.ApiRelease(this);
this.apiOperation = new operations.ApiOperation(this);
this.apiOperationPolicy = new operations.ApiOperationPolicy(this);
this.tag = new operations.Tag(this);
this.apiProduct = new operations.ApiProduct(this);
this.apiPolicy = new operations.ApiPolicy(this);
this.apiSchema = new operations.ApiSchema(this);
this.apiDiagnostic = new operations.ApiDiagnostic(this);
this.apiDiagnosticLogger = new operations.ApiDiagnosticLogger(this);
this.apiIssue = new operations.ApiIssue(this);
this.apiIssueComment = new operations.ApiIssueComment(this);
this.apiIssueAttachment = new operations.ApiIssueAttachment(this);
this.apiTagDescription = new operations.ApiTagDescription(this);
this.operation = new operations.OperationOperations(this);
this.apiVersionSet = new operations.ApiVersionSet(this);
this.authorizationServer = new operations.AuthorizationServer(this);
this.backend = new operations.Backend(this);
this.cache = new operations.Cache(this);
this.certificate = new operations.Certificate(this);
this.apiManagementOperations = new operations.ApiManagementOperations(this);
this.apiManagementServiceSkus = new operations.ApiManagementServiceSkus(this);
this.apiManagementService = new operations.ApiManagementService(this);
this.diagnostic = new operations.Diagnostic(this);
this.diagnosticLogger = new operations.DiagnosticLogger(this);
this.emailTemplate = new operations.EmailTemplate(this);
this.group = new operations.Group(this);
this.groupUser = new operations.GroupUser(this);
this.identityProvider = new operations.IdentityProvider(this);
this.issue = new operations.Issue(this);
this.logger = new operations.Logger(this);
this.networkStatus = new operations.NetworkStatus(this);
this.notification = new operations.Notification(this);
this.notificationRecipientUser = new operations.NotificationRecipientUser(this);
this.notificationRecipientEmail = new operations.NotificationRecipientEmail(this);
this.networkStatus = new operations.NetworkStatus(this);
this.openIdConnectProvider = new operations.OpenIdConnectProvider(this);
this.policy = new operations.Policy(this);
this.policySnippet = new operations.PolicySnippet(this);
this.signInSettings = new operations.SignInSettings(this);
this.signUpSettings = new operations.SignUpSettings(this);
this.delegationSettings = new operations.DelegationSettings(this);
Expand All @@ -130,20 +136,18 @@ class ApiManagementClient extends ApiManagementClientContext {
this.property = new operations.Property(this);
this.quotaByCounterKeys = new operations.QuotaByCounterKeys(this);
this.quotaByPeriodKeys = new operations.QuotaByPeriodKeys(this);
this.region = new operations.Region(this);
this.reports = new operations.Reports(this);
this.subscription = new operations.Subscription(this);
this.tagResource = new operations.TagResource(this);
this.tag = new operations.Tag(this);
this.tagDescription = new operations.TagDescription(this);
this.operation = new operations.OperationOperations(this);
this.tenantAccess = new operations.TenantAccess(this);
this.tenantAccessGit = new operations.TenantAccessGit(this);
this.tenantConfiguration = new operations.TenantConfiguration(this);
this.user = new operations.User(this);
this.userGroup = new operations.UserGroup(this);
this.userSubscription = new operations.UserSubscription(this);
this.userIdentities = new operations.UserIdentities(this);
this.apiVersionSet = new operations.ApiVersionSet(this);
this.userConfirmationPassword = new operations.UserConfirmationPassword(this);
this.apiExport = new operations.ApiExport(this);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import * as msRest from "@azure/ms-rest-js";
import * as msRestAzure from "@azure/ms-rest-azure-js";

const packageName = "@azure/arm-apimanagement";
const packageVersion = "0.1.0";
const packageVersion = "4.4.0";

export class ApiManagementClientContext extends msRestAzure.AzureServiceClient {
credentials: msRest.ServiceClientCredentials;
Expand Down Expand Up @@ -45,7 +45,7 @@ export class ApiManagementClientContext extends msRestAzure.AzureServiceClient {

super(credentials, options);

this.apiVersion = '2018-01-01';
this.apiVersion = '2019-01-01';
this.acceptLanguage = 'en-US';
this.longRunningOperationRetryTimeout = 30;
this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,32 +13,40 @@ export {
DiagnosticContract,
Resource,
BaseResource,
SamplingSettings,
PipelineDiagnosticSettings,
HttpMessageDiagnostic,
BodyDiagnosticSettings,
ErrorResponse,
ErrorFieldContract,
ApiDiagnosticGetEntityTagHeaders,
ApiDiagnosticGetHeaders,
ApiDiagnosticCreateOrUpdateHeaders,
TagContract,
TagDescriptionContract,
IssueAttachmentContract,
IssueCommentContract,
IssueContract,
SchemaContract,
PolicyContract,
ProductContract,
OperationContract,
ParameterContract,
RequestContract,
RepresentationContract,
ResponseContract,
ApiReleaseContract,
ApiContract,
AuthenticationSettingsContract,
OAuth2AuthenticationSettingsContract,
OpenIdAuthenticationSettingsContract,
SubscriptionKeyParameterNamesContract,
ApiVersionSetContractDetails,
ApiReleaseContract,
OperationContract,
ParameterContract,
RequestContract,
RepresentationContract,
ResponseContract,
SchemaContract,
IssueContract,
IssueCommentContract,
IssueAttachmentContract,
LoggerContract,
ProductContract,
AuthorizationServerContract,
TokenBodyParameterContract,
ApiVersionSetContract,
AuthorizationServerUpdateContract,
TokenBodyParameterContract,
AuthorizationServerContract,
BackendReconnectContract,
BackendContract,
BackendProperties,
BackendServiceFabricClusterProperties,
Expand All @@ -47,7 +55,7 @@ export {
BackendAuthorizationHeaderCredentials,
BackendProxyContract,
BackendTlsProperties,
BackendReconnectContract,
CacheContract,
CertificateContract,
ApimResource,
ApiManagementServiceUpdateParameters,
Expand All @@ -60,27 +68,25 @@ export {
ApiManagementServiceIdentity,
EmailTemplateContract,
EmailTemplateParametersContractProperties,
GroupContract,
UserContract,
UserIdentityContract,
GroupContractProperties,
GroupContract,
IdentityProviderContract,
LoggerContract,
RecipientEmailContract,
RecipientUserContract,
NotificationContract,
RecipientsContractProperties,
RecipientUserContract,
RecipientEmailContract,
OpenidConnectProviderContract,
PortalSigninSettings,
PortalSignupSettings,
TermsOfServiceProperties,
PortalDelegationSettings,
SubscriptionsDelegationSettingsProperties,
RegistrationDelegationSettingsProperties,
PortalSignupSettings,
TermsOfServiceProperties,
PortalSigninSettings,
SubscriptionContract,
PropertyContract,
TagContract,
TagDescriptionContract,
ApiVersionSetContract,
ApiManagementServiceResource
} from "../models/mappers";

Loading