Iot Hub Resource - Create Event Hub Consumer Group

Fügen Sie eine Consumergruppe zu einem Event Hub-kompatiblen Endpunkt in einem IoT Hub hinzu.

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Devices/IotHubs/{resourceName}/eventHubEndpoints/{eventHubEndpointName}/ConsumerGroups/{name}?api-version=2018-04-01

URI-Parameter

Name In Erforderlich Typ Beschreibung
eventHubEndpointName
path True

string

Der Name des Event Hub-kompatiblen Endpunkts im IoT Hub.

name
path True

string

Der Name der hinzuzufügenden Consumergruppe.

resourceGroupName
path True

string

Der Name der Ressourcengruppe, die den IoT Hub enthält.

resourceName
path True

string

Der Name des IoT-Hubs.

subscriptionId
path True

string

Die Abonnement-ID.

api-version
query True

string

Die Version der API.

Antworten

Name Typ Beschreibung
200 OK

EventHubConsumerGroupInfo

Dies ist ein synchroner Vorgang.

Other Status Codes

ErrorDetails

DefaultErrorResponse

Sicherheit

azure_auth

Azure Active Directory-OAuth2-Flow

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

Scopes

Name Beschreibung
user_impersonation Identitätswechsel Ihres Benutzerkontos

Beispiele

IotHubResource_CreateEventHubConsumerGroup

Sample Request

PUT https://management.azure.com/subscriptions/91d12660-3dec-467a-be2a-213b5544ddc0/resourceGroups/myResourceGroup/providers/Microsoft.Devices/IotHubs/testHub/eventHubEndpoints/events/ConsumerGroups/test?api-version=2018-04-01

Sample Response

{
  "properties": {
    "created": "Thu, 15 Jun 2017 19:20:58 GMT"
  },
  "id": "/subscriptions/cmd-sub-1/resourceGroups/cmd-rg-1/providers/Microsoft.Devices/IotHubs/test-hub-2/eventHubEndpoints/events/ConsumerGroups/%24Default",
  "name": "test",
  "type": "Microsoft.Devices/IotHubs/EventHubEndpoints/ConsumerGroups",
  "etag": "AAAAAAFD6M4="
}

Definitionen

Name Beschreibung
ErrorDetails

Fehlerdetails.

EventHubConsumerGroupInfo

Die Eigenschaften des EventHubConsumerGroupInfo-Objekts.

ErrorDetails

Fehlerdetails.

Name Typ Beschreibung
code

string

Der Fehlercode.

details

string

Die Fehlerdetails.

httpStatusCode

string

Der HTTP-Statuscode.

message

string

Die Fehlermeldung.

EventHubConsumerGroupInfo

Die Eigenschaften des EventHubConsumerGroupInfo-Objekts.

Name Typ Beschreibung
etag

string

Das Etag.

id

string

Der Event Hub-kompatible Consumergruppenbezeichner.

name

string

Der Name der Event Hub-kompatiblen Consumergruppe.

properties

object

Die Tags.

type

string

der Ressourcentyp.