diff --git a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/models.go b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/models.go index 334e5b41e507..de494a9087b3 100644 --- a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/models.go +++ b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/models.go @@ -39,13 +39,13 @@ const ( Listen AccessRights = "Listen" // Manage ... Manage AccessRights = "Manage" - // Send ... - Send AccessRights = "Send" + // SendEnumValue ... + SendEnumValue AccessRights = "Send" ) // PossibleAccessRightsValues returns an array of possible values for the AccessRights const type. func PossibleAccessRightsValues() []AccessRights { - return []AccessRights{Listen, Manage, Send} + return []AccessRights{Listen, Manage, SendEnumValue} } // NamespaceType enumerates the values for namespace type. @@ -168,23 +168,25 @@ func (ac *ApnsCredential) UnmarshalJSON(body []byte) error { return nil } -// ApnsCredentialProperties description of a NotificationHub ApnsCredential. +// ApnsCredentialProperties description of a NotificationHub ApnsCredential. Note that there is no explicit +// switch between Certificate and Token Authentication Modes. The mode is determined based on the +// properties passed in. type ApnsCredentialProperties struct { - // ApnsCertificate - The APNS certificate. + // ApnsCertificate - The APNS certificate. Specify if using Certificate Authentication Mode. ApnsCertificate *string `json:"apnsCertificate,omitempty"` - // CertificateKey - The certificate key. + // CertificateKey - The APNS certificate password if it exists. CertificateKey *string `json:"certificateKey,omitempty"` - // Endpoint - The endpoint of this credential. + // Endpoint - The APNS endpoint of this credential. If using Certificate Authentication Mode and Sandbox specify 'gateway.sandbox.push.apple.com'. If using Certificate Authentication Mode and Production specify 'gateway.push.apple.com'. If using Token Authentication Mode and Sandbox specify 'https://api.development.push.apple.com:443/3/device'. If using Token Authentication Mode and Production specify 'https://api.push.apple.com:443/3/device'. Endpoint *string `json:"endpoint,omitempty"` - // Thumbprint - The APNS certificate Thumbprint + // Thumbprint - The APNS certificate thumbprint. Specify if using Certificate Authentication Mode. Thumbprint *string `json:"thumbprint,omitempty"` - // KeyID - A 10-character key identifier (kid) key, obtained from your developer account + // KeyID - A 10-character key identifier (kid) key, obtained from your developer account. Specify if using Token Authentication Mode. KeyID *string `json:"keyId,omitempty"` - // AppName - The name of the application + // AppName - The name of the application or BundleId. Specify if using Token Authentication Mode. AppName *string `json:"appName,omitempty"` - // AppID - The issuer (iss) registered claim key, whose value is your 10-character Team ID, obtained from your developer account + // AppID - The issuer (iss) registered claim key. The value is a 10-character TeamId, obtained from your developer account. Specify if using Token Authentication Mode. AppID *string `json:"appId,omitempty"` - // Token - Provider Authentication Token, obtained through your developer account + // Token - Provider Authentication Token, obtained through your developer account. Specify if using Token Authentication Mode. Token *string `json:"token,omitempty"` } @@ -603,7 +605,7 @@ func (gc *GcmCredential) UnmarshalJSON(body []byte) error { // GcmCredentialProperties description of a NotificationHub GcmCredential. type GcmCredentialProperties struct { - // GcmEndpoint - The GCM endpoint. + // GcmEndpoint - The FCM legacy endpoint. Default value is 'https://fcm.googleapis.com/fcm/send' GcmEndpoint *string `json:"gcmEndpoint,omitempty"` // GoogleAPIKey - The Google API key. GoogleAPIKey *string `json:"googleApiKey,omitempty"` diff --git a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/namespaces.go b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/namespaces.go index 1cac9b1db30c..e7fd460f21b6 100644 --- a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/namespaces.go +++ b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/namespaces.go @@ -118,7 +118,6 @@ func (client NamespacesClient) CheckAvailabilitySender(req *http.Request) (*http func (client NamespacesClient) CheckAvailabilityResponder(resp *http.Response) (result CheckAvailabilityResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -198,7 +197,6 @@ func (client NamespacesClient) CreateOrUpdateSender(req *http.Request) (*http.Re func (client NamespacesClient) CreateOrUpdateResponder(resp *http.Response) (result NamespaceResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -285,7 +283,6 @@ func (client NamespacesClient) CreateOrUpdateAuthorizationRuleSender(req *http.R func (client NamespacesClient) CreateOrUpdateAuthorizationRuleResponder(resp *http.Response) (result SharedAccessAuthorizationRuleResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -362,7 +359,6 @@ func (client NamespacesClient) DeleteSender(req *http.Request) (future Namespace func (client NamespacesClient) DeleteResponder(resp *http.Response) (result autorest.Response, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusAccepted, http.StatusNoContent), autorest.ByClosing()) result.Response = resp @@ -439,7 +435,6 @@ func (client NamespacesClient) DeleteAuthorizationRuleSender(req *http.Request) func (client NamespacesClient) DeleteAuthorizationRuleResponder(resp *http.Response) (result autorest.Response, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent), autorest.ByClosing()) result.Response = resp @@ -514,7 +509,6 @@ func (client NamespacesClient) GetSender(req *http.Request) (*http.Response, err func (client NamespacesClient) GetResponder(resp *http.Response) (result NamespaceResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -592,7 +586,6 @@ func (client NamespacesClient) GetAuthorizationRuleSender(req *http.Request) (*h func (client NamespacesClient) GetAuthorizationRuleResponder(resp *http.Response) (result SharedAccessAuthorizationRuleResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -668,7 +661,6 @@ func (client NamespacesClient) ListSender(req *http.Request) (*http.Response, er func (client NamespacesClient) ListResponder(resp *http.Response) (result NamespaceListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -777,7 +769,6 @@ func (client NamespacesClient) ListAllSender(req *http.Request) (*http.Response, func (client NamespacesClient) ListAllResponder(resp *http.Response) (result NamespaceListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -891,7 +882,6 @@ func (client NamespacesClient) ListAuthorizationRulesSender(req *http.Request) ( func (client NamespacesClient) ListAuthorizationRulesResponder(resp *http.Response) (result SharedAccessAuthorizationRuleListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1006,7 +996,6 @@ func (client NamespacesClient) ListKeysSender(req *http.Request) (*http.Response func (client NamespacesClient) ListKeysResponder(resp *http.Response) (result SharedAccessAuthorizationRuleListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1085,7 +1074,6 @@ func (client NamespacesClient) PatchSender(req *http.Request) (*http.Response, e func (client NamespacesClient) PatchResponder(resp *http.Response) (result NamespaceResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1166,7 +1154,6 @@ func (client NamespacesClient) RegenerateKeysSender(req *http.Request) (*http.Re func (client NamespacesClient) RegenerateKeysResponder(resp *http.Response) (result ResourceListKeys, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) diff --git a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/notificationhubs.go b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/notificationhubs.go index 6f716a3a5f8a..4765e57fd050 100644 --- a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/notificationhubs.go +++ b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/notificationhubs.go @@ -121,7 +121,6 @@ func (client Client) CheckNotificationHubAvailabilitySender(req *http.Request) ( func (client Client) CheckNotificationHubAvailabilityResponder(resp *http.Response) (result CheckAvailabilityResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -208,7 +207,6 @@ func (client Client) CreateOrUpdateSender(req *http.Request) (*http.Response, er func (client Client) CreateOrUpdateResponder(resp *http.Response) (result ResourceType, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -297,7 +295,6 @@ func (client Client) CreateOrUpdateAuthorizationRuleSender(req *http.Request) (* func (client Client) CreateOrUpdateAuthorizationRuleResponder(resp *http.Response) (result SharedAccessAuthorizationRuleResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -381,7 +378,6 @@ func (client Client) DebugSendSender(req *http.Request) (*http.Response, error) func (client Client) DebugSendResponder(resp *http.Response) (result DebugSendResponse, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusCreated), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -459,7 +455,6 @@ func (client Client) DeleteSender(req *http.Request) (*http.Response, error) { func (client Client) DeleteResponder(resp *http.Response) (result autorest.Response, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByClosing()) result.Response = resp @@ -538,7 +533,6 @@ func (client Client) DeleteAuthorizationRuleSender(req *http.Request) (*http.Res func (client Client) DeleteAuthorizationRuleResponder(resp *http.Response) (result autorest.Response, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK, http.StatusNoContent), autorest.ByClosing()) result.Response = resp @@ -615,7 +609,6 @@ func (client Client) GetSender(req *http.Request) (*http.Response, error) { func (client Client) GetResponder(resp *http.Response) (result ResourceType, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -695,7 +688,6 @@ func (client Client) GetAuthorizationRuleSender(req *http.Request) (*http.Respon func (client Client) GetAuthorizationRuleResponder(resp *http.Response) (result SharedAccessAuthorizationRuleResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -773,7 +765,6 @@ func (client Client) GetPnsCredentialsSender(req *http.Request) (*http.Response, func (client Client) GetPnsCredentialsResponder(resp *http.Response) (result PnsCredentialsResource, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -850,7 +841,6 @@ func (client Client) ListSender(req *http.Request) (*http.Response, error) { func (client Client) ListResponder(resp *http.Response) (result ListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -966,7 +956,6 @@ func (client Client) ListAuthorizationRulesSender(req *http.Request) (*http.Resp func (client Client) ListAuthorizationRulesResponder(resp *http.Response) (result SharedAccessAuthorizationRuleListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1083,7 +1072,6 @@ func (client Client) ListKeysSender(req *http.Request) (*http.Response, error) { func (client Client) ListKeysResponder(resp *http.Response) (result ResourceListKeys, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1167,7 +1155,6 @@ func (client Client) PatchSender(req *http.Request) (*http.Response, error) { func (client Client) PatchResponder(resp *http.Response) (result ResourceType, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) @@ -1250,7 +1237,6 @@ func (client Client) RegenerateKeysSender(req *http.Request) (*http.Response, er func (client Client) RegenerateKeysResponder(resp *http.Response) (result ResourceListKeys, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) diff --git a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/operations.go b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/operations.go index 0e420db180db..b9ddcf01c01f 100644 --- a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/operations.go +++ b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/operations.go @@ -101,7 +101,6 @@ func (client OperationsClient) ListSender(req *http.Request) (*http.Response, er func (client OperationsClient) ListResponder(resp *http.Response) (result OperationListResult, err error) { err = autorest.Respond( resp, - client.ByInspecting(), azure.WithErrorUnlessStatusCode(http.StatusOK), autorest.ByUnmarshallingJSON(&result), autorest.ByClosing()) diff --git a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/version.go b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/version.go index ffc3623204c0..adf77d0e2a30 100644 --- a/services/notificationhubs/mgmt/2017-04-01/notificationhubs/version.go +++ b/services/notificationhubs/mgmt/2017-04-01/notificationhubs/version.go @@ -21,7 +21,7 @@ import "github.com/Azure/azure-sdk-for-go/version" // UserAgent returns the UserAgent string to use when sending http.Requests. func UserAgent() string { - return "Azure-SDK-For-Go/" + version.Number + " notificationhubs/2017-04-01" + return "Azure-SDK-For-Go/" + Version() + " notificationhubs/2017-04-01" } // Version returns the semantic version (see http://semver.org) of the client.