Azure Event Hubs Authorization Rules API

Operations for managing authorization rules and access keys.

Operations 6

GET /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules Azure Event Hubs List namespace authorization rules #
PUT /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName} Azure Event Hubs Create or update namespace authorization rule #
GET /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName} Azure Event Hubs Get namespace authorization rule #
DELETE /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName} Azure Event Hubs Delete namespace authorization rule #
POST /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}/listKeys Azure Event Hubs List namespace keys #
POST /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}/regenerateKeys Azure Event Hubs Regenerate namespace keys #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/microsoft-azure-event-hubs-authorization-rules-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

microsoft-azure-event-hubs-authorization-rules-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Azure Event Hubs Management REST Authorization Rules API
  description: Azure Resource Manager REST API for managing Event Hubs namespaces, event hubs, consumer groups, authorization rules, disaster recovery configurations, and schema registry groups. This API uses the Microsoft.EventHub resource provider and operates on the Azure management plane at management.azure.com.
  version: '2024-01-01'
  contact:
    name: Microsoft Azure Support
    url: https://azure.microsoft.com/en-us/support/
  license:
    name: Microsoft Azure Terms of Service
    url: https://azure.microsoft.com/en-us/support/legal/
  x-logo:
    url: https://azure.microsoft.com/svghandler/event-hubs/
servers:
- url: https://management.azure.com
  description: Azure Resource Manager
security:
- azure_auth:
  - user_impersonation
tags:
- name: Authorization Rules
  description: Operations for managing authorization rules and access keys.
paths:
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules
  : get:
      operationId: Namespaces_ListAuthorizationRules
      summary: Azure Event Hubs List namespace authorization rules
      description: Gets a list of authorization rules for a Namespace.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      responses:
        '200':
          description: Namespace authorization rules returned successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthorizationRuleListResult'
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}
  : put:
      operationId: Namespaces_CreateOrUpdateAuthorizationRule
      summary: Azure Event Hubs Create or update namespace authorization rule
      description: Creates or updates an AuthorizationRule for a Namespace.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/AuthorizationRuleNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      requestBody:
        required: true
        description: The shared access AuthorizationRule.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/AuthorizationRule'
      responses:
        '200':
          description: Namespace authorization rule created.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthorizationRule'
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
    get:
      operationId: Namespaces_GetAuthorizationRule
      summary: Azure Event Hubs Get namespace authorization rule
      description: Gets an AuthorizationRule for a Namespace by rule name.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/AuthorizationRuleNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      responses:
        '200':
          description: Namespace authorization rule returned successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthorizationRule'
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
    delete:
      operationId: Namespaces_DeleteAuthorizationRule
      summary: Azure Event Hubs Delete namespace authorization rule
      description: Deletes an AuthorizationRule for a Namespace.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/AuthorizationRuleNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      responses:
        '200':
          description: Namespace authorization rule deleted.
        '204':
          description: No content.
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}/listKeys
  : post:
      operationId: Namespaces_ListKeys
      summary: Azure Event Hubs List namespace keys
      description: Gets the primary and secondary connection strings for the Namespace.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/AuthorizationRuleNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      responses:
        '200':
          description: Connection strings returned successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccessKeys'
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
  ? /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/authorizationRules/{authorizationRuleName}/regenerateKeys
  : post:
      operationId: Namespaces_RegenerateKeys
      summary: Azure Event Hubs Regenerate namespace keys
      description: Regenerates the primary or secondary connection strings for the specified Namespace.
      tags:
      - Authorization Rules
      parameters:
      - $ref: '#/components/parameters/SubscriptionIdParameter'
      - $ref: '#/components/parameters/ResourceGroupNameParameter'
      - $ref: '#/components/parameters/NamespaceNameParameter'
      - $ref: '#/components/parameters/AuthorizationRuleNameParameter'
      - $ref: '#/components/parameters/ApiVersionParameter'
      requestBody:
        required: true
        description: Parameters supplied to regenerate the authorization rule.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RegenerateAccessKeyParameters'
      responses:
        '200':
          description: Authorization rule regenerated successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AccessKeys'
        default:
          description: Event Hubs error response describing why the operation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    ErrorResponse:
      type: object
      description: Error response indicates Event Hub service is not able to process the incoming request. The reason is provided in the error message.
      properties:
        error:
          $ref: '#/components/schemas/ErrorDetail'
    AccessKeys:
      type: object
      description: Namespace/EventHub Connection String.
      properties:
        primaryConnectionString:
          type: string
          readOnly: true
          description: Primary connection string of the created namespace AuthorizationRule.
        secondaryConnectionString:
          type: string
          readOnly: true
          description: Secondary connection string of the created namespace AuthorizationRule.
        aliasPrimaryConnectionString:
          type: string
          readOnly: true
          description: Primary connection string of the alias if GEO DR is enabled.
        aliasSecondaryConnectionString:
          type: string
          readOnly: true
          description: Secondary connection string of the alias if GEO DR is enabled.
        primaryKey:
          type: string
          readOnly: true
          description: A base64-encoded 256-bit primary key for signing and validating the SAS token.
        secondaryKey:
          type: string
          readOnly: true
          description: A base64-encoded 256-bit secondary key for signing and validating the SAS token.
        keyName:
          type: string
          readOnly: true
          description: A string that describes the AuthorizationRule.
    SystemData:
      type: object
      description: Metadata pertaining to creation and last modification of the resource.
      properties:
        createdBy:
          type: string
          description: The identity that created the resource.
        createdByType:
          type: string
          description: The type of identity that created the resource.
          enum:
          - User
          - Application
          - ManagedIdentity
          - Key
        createdAt:
          type: string
          format: date-time
          description: The timestamp of resource creation (UTC).
        lastModifiedBy:
          type: string
          description: The identity that last modified the resource.
        lastModifiedByType:
          type: string
          description: The type of identity that last modified the resource.
          enum:
          - User
          - Application
          - ManagedIdentity
          - Key
        lastModifiedAt:
          type: string
          format: date-time
          description: The timestamp of resource last modification (UTC).
    RegenerateAccessKeyParameters:
      type: object
      description: Parameters supplied to the Regenerate Authorization Rule operation.
      required:
      - keyType
      properties:
        keyType:
          type: string
          description: The access key to regenerate.
          enum:
          - PrimaryKey
          - SecondaryKey
        key:
          type: string
          description: Optional. If the key value is provided, this is set to key type, or autogenerated key value set for keyType.
    AuthorizationRule:
      type: object
      description: Single item in a List or Get AuthorizationRule operation.
      properties:
        id:
          type: string
          readOnly: true
          description: Fully qualified resource ID for the resource.
        name:
          type: string
          readOnly: true
          description: The name of the resource.
        type:
          type: string
          readOnly: true
          description: The type of the resource.
        properties:
          type: object
          properties:
            rights:
              type: array
              items:
                type: string
                enum:
                - Manage
                - Send
                - Listen
              description: The rights associated with the rule.
        systemData:
          $ref: '#/components/schemas/SystemData'
    ErrorDetail:
      type: object
      description: The error detail.
      properties:
        code:
          type: string
          readOnly: true
          description: The error code.
        message:
          type: string
          readOnly: true
          description: The error message.
        target:
          type: string
          readOnly: true
          description: The error target.
        details:
          type: array
          items:
            $ref: '#/components/schemas/ErrorDetail'
          readOnly: true
          description: The error details.
        additionalInfo:
          type: array
          items:
            $ref: '#/components/schemas/ErrorAdditionalInfo'
          readOnly: true
          description: The error additional info.
    ErrorAdditionalInfo:
      type: object
      description: The resource management error additional info.
      properties:
        type:
          type: string
          readOnly: true
          description: The additional info type.
        info:
          type: object
          readOnly: true
          description: The additional info.
    AuthorizationRuleListResult:
      type: object
      description: The response from the List namespace operation.
      properties:
        value:
          type: array
          items:
            $ref: '#/components/schemas/AuthorizationRule'
          description: Result of the List Authorization Rules operation.
        nextLink:
          type: string
          description: Link to the next set of results.
  parameters:
    SubscriptionIdParameter:
      name: subscriptionId
      in: path
      required: true
      description: Subscription credentials that uniquely identify a Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
      schema:
        type: string
    ApiVersionParameter:
      name: api-version
      in: query
      required: true
      description: Client API version.
      schema:
        type: string
        default: '2024-01-01'
    NamespaceNameParameter:
      name: namespaceName
      in: path
      required: true
      description: The Namespace name.
      schema:
        type: string
        minLength: 6
        maxLength: 50
        pattern: ^[a-zA-Z][a-zA-Z0-9-]{6,50}[a-zA-Z0-9]$
    AuthorizationRuleNameParameter:
      name: authorizationRuleName
      in: path
      required: true
      description: The authorization rule name.
      schema:
        type: string
        minLength: 1
    ResourceGroupNameParameter:
      name: resourceGroupName
      in: path
      required: true
      description: Name of the resource group within the Azure subscription.
      schema:
        type: string
        minLength: 1
        maxLength: 90
  securitySchemes:
    azure_auth:
      type: oauth2
      description: Azure Active Directory OAuth2 Flow.
      flows:
        implicit:
          authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
          scopes:
            user_impersonation: Impersonate your user account