共用方式為


Namespaces - Authorization Rules - Get Authorization Rule

依規則名稱取得命名空間的授權規則。

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ServiceBus/namespaces/{namespaceName}/AuthorizationRules/{authorizationRuleName}?api-version=2024-01-01

URI 參數

名稱 位於 必要 類型 Description
authorizationRuleName
path True

string

minLength: 1
maxLength: 50

授權規則名稱。

namespaceName
path True

string

minLength: 6
maxLength: 50

命名空間名稱

resourceGroupName
path True

string

minLength: 1
maxLength: 90

資源群組的名稱。 名稱不區分大小寫。

subscriptionId
path True

string

可唯一識別Microsoft Azure 訂用帳戶的訂用帳戶認證。 訂用帳戶標識碼會形成每個服務呼叫 URI 的一部分。

api-version
query True

string

minLength: 1

要用於這項作業的 API 版本。

回應

名稱 類型 Description
200 OK

SBAuthorizationRule

已成功傳回命名空間授權規則。

Other Status Codes

ErrorResponse

描述作業失敗原因的 ServiceBus 錯誤回應。

安全性

azure_auth

Azure Active Directory OAuth2 Flow

類型: oauth2
Flow: implicit
授權 URL: https://login.microsoftonline.com/common/oauth2/authorize

範圍

名稱 Description
user_impersonation 模擬您的用戶帳戶

範例

NameSpaceAuthorizationRuleGet

範例要求

GET https://management.azure.com/subscriptions/5f750a97-50d9-4e36-8081-c9ee4c0210d4/resourceGroups/ArunMonocle/providers/Microsoft.ServiceBus/namespaces/sdk-Namespace-6914/AuthorizationRules/sdk-AuthRules-1788?api-version=2024-01-01

範例回覆

{
  "id": "/subscriptions/5f750a97-50d9-4e36-8081-c9ee4c0210d4/resourceGroups/ArunMonocle/providers/Microsoft.ServiceBus/namespaces/sdk-Namespace-6914/AuthorizationRules/sdk-AuthRules-1788/",
  "name": "sdk-AuthRules-1788",
  "type": "Microsoft.ServiceBus/Namespaces/AuthorizationRules",
  "properties": {
    "rights": [
      "Listen",
      "Send"
    ]
  }
}

定義

名稱 Description
AccessRights

與規則相關聯的許可權。

createdByType

建立資源的身分識別類型。

Error

error 物件。

ErrorAdditionalInfo

資源管理錯誤其他資訊。

ErrorResponse

資源管理錯誤回應。

SBAuthorizationRule

命名空間授權規則的描述。

systemData

與建立和上次修改資源相關的元數據。

AccessRights

與規則相關聯的許可權。

Description
Listen
Manage
Send

createdByType

建立資源的身分識別類型。

Description
Application
Key
ManagedIdentity
User

Error

error 物件。

名稱 類型 Description
additionalInfo

ErrorAdditionalInfo[]

錯誤其他資訊。

code

string

錯誤碼。

details

ErrorResponse[]

錯誤詳細數據。

message

string

錯誤訊息。

target

string

錯誤目標。

ErrorAdditionalInfo

資源管理錯誤其他資訊。

名稱 類型 Description
info

object

其他資訊。

type

string

其他信息類型。

ErrorResponse

資源管理錯誤回應。

名稱 類型 Description
error

Error

error 物件。

SBAuthorizationRule

命名空間授權規則的描述。

名稱 類型 Description
id

string

資源的完整資源標識碼。 例如 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}

location

string

資源所在的地理位置

name

string

資源的名稱

properties.rights

AccessRights[]

與規則相關聯的許可權。

systemData

systemData

與此資源相關的系統元數據。

type

string

資源的型別。 例如“Microsoft.EventHub/Namespaces” 或 “Microsoft.EventHub/Namespaces/EventHubs”

systemData

與建立和上次修改資源相關的元數據。

名稱 類型 Description
createdAt

string (date-time)

資源建立的時間戳(UTC)。

createdBy

string

建立資源的身分識別。

createdByType

createdByType

建立資源的身分識別類型。

lastModifiedAt

string (date-time)

上次修改資源的身分識別類型。

lastModifiedBy

string

上次修改資源的身分識別。

lastModifiedByType

createdByType

上次修改資源的身分識別類型。