Notification Hubs - List Keys

Lekéri az elsődleges és a másodlagos connectionStringset a NotificationHubra

POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.NotificationHubs/namespaces/{namespaceName}/notificationHubs/{notificationHubName}/authorizationRules/{authorizationRuleName}/listKeys?api-version=2023-09-01

URI-paraméterek

Name In Kötelező Típus Description
authorizationRuleName
path True

string

Engedélyezési szabály neve

Regex pattern: ^[a-zA-Z0-9!()*-._]+$

namespaceName
path True

string

Névtér neve

Regex pattern: ^[a-zA-Z][a-zA-Z0-9-]*$

notificationHubName
path True

string

Értesítési központ neve

Regex pattern: ^[a-zA-Z][a-zA-Z0-9-./_]*$

resourceGroupName
path True

string

Az erőforráscsoport neve. A név megkülönbözteti a kis- és nagybetűket.

subscriptionId
path True

string

uuid

A cél-előfizetés azonosítója. Az értéknek UUID-nak kell lennie.

api-version
query True

string

A művelethez használandó API-verzió.

Válaszok

Name Típus Description
200 OK

ResourceListKeys

Siker

Other Status Codes

ErrorResponse

Hibakód okokkal.

Biztonság

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation felhasználói fiók megszemélyesítése

Példák

NotificationHubs_ListKeys

Sample Request

POST https://management.azure.com/subscriptions/29cfa613-cbbc-4512-b1d6-1b3a92c7fa40/resourceGroups/5ktrial/providers/Microsoft.NotificationHubs/namespaces/nh-sdk-ns/notificationHubs/nh-sdk-hub/authorizationRules/sdk-AuthRules-5800/listKeys?api-version=2023-09-01

Sample Response

{
  "primaryConnectionString": "Endpoint=sb://nh-sdk-ns.servicebus.windows-int.net/;SharedAccessKeyName=sdk-AuthRules-5800;SharedAccessKey=############################################;EntityPath=sdk-notificationHubs-2317",
  "secondaryConnectionString": "Endpoint=sb://nh-sdk-ns.servicebus.windows-int.net/;SharedAccessKeyName=sdk-AuthRules-5800;SharedAccessKey=############################################;EntityPath=sdk-notificationHubs-2317",
  "primaryKey": "############################################",
  "secondaryKey": "############################################",
  "keyName": "sdk-AuthRules-5800"
}

Definíciók

Name Description
ErrorAdditionalInfo

Az erőforrás-kezelési hiba további információi.

ErrorDetail

A hiba részletei.

ErrorResponse

Hibaválasz

ResourceListKeys

Válasz a NÉVtér vagy a NotificationHub hozzáférési kulcsait (kapcsolati sztringeket) visszakérő POST-kérelemre.

ErrorAdditionalInfo

Az erőforrás-kezelési hiba további információi.

Name Típus Description
info

object

A további információk.

type

string

A további információtípus.

ErrorDetail

A hiba részletei.

Name Típus Description
additionalInfo

ErrorAdditionalInfo[]

A hiba további információi.

code

string

A hibakód.

details

ErrorDetail[]

A hiba részletei.

message

string

A hibaüzenet.

target

string

A hibacél.

ErrorResponse

Hibaválasz

Name Típus Description
error

ErrorDetail

A hibaobjektum.

ResourceListKeys

Válasz a NÉVtér vagy a NotificationHub hozzáférési kulcsait (kapcsolati sztringeket) visszakérő POST-kérelemre.

Name Típus Description
keyName

string

Lekéri vagy beállítja a létrehozott AuthorizationRule kulcsnevét

primaryConnectionString

string

Lekéri vagy beállítja az AuthorizationRule primaryConnectionString elemét.

primaryKey

string

Lekéri vagy beállítja a létrehozott AuthorizationRule primaryKey elemét.

secondaryConnectionString

string

Lekéri vagy beállítja a létrehozott AuthorizationRule secondaryConnectionString elemét

secondaryKey

string

Lekéri vagy beállítja a létrehozott AuthorizationRule másodlagos kulcsát