> ## Documentation Index
> Fetch the complete documentation index at: https://docs.open-metadata.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Retrieve a Messaging Service

> Get a messaging service by ID or fully qualified name

# Retrieve a Messaging Service

Get a single messaging service by its unique ID or fully qualified name.

## Get by ID

<ParamField path="id" type="string" required>
  UUID of the messaging service to retrieve.
</ParamField>

<ParamField query="fields" type="string">
  Comma-separated list of fields to include. Valid fields: `pipelines`, `owners`, `tags`, `domains`, `followers`.
</ParamField>

<ParamField query="include" type="string" default="non-deleted">
  Include `all`, `deleted`, or `non-deleted` entities.
</ParamField>

## Get by Fully Qualified Name

Use `GET /v1/services/messagingServices/name/{fqn}` to retrieve by fully qualified name.

<ParamField path="fqn" type="string" required>
  Fully qualified name of the messaging service (e.g., `sample_kafka`).
</ParamField>

<ParamField query="fields" type="string">
  Comma-separated list of fields to include. Valid fields: `pipelines`, `owners`, `tags`, `domains`, `followers`.
</ParamField>

<ParamField query="include" type="string" default="non-deleted">
  Include `all`, `deleted`, or `non-deleted` entities.
</ParamField>

<RequestExample dropdown>
  ```python GET /v1/services/messagingServices/{id} theme={null}
  import requests

  base_url = "https://your-company.open-metadata.org/api"
  headers = {"Authorization": "Bearer your-jwt-token"}

  # Get by ID
  response = requests.get(
      f"{base_url}/v1/services/messagingServices/469ef25e-9bdf-4d5f-8553-eb0ce8581f30",
      headers=headers
  )
  service = response.json()
  print(f"{service['fullyQualifiedName']}: {service['serviceType']}")

  # Get by ID with fields
  response = requests.get(
      f"{base_url}/v1/services/messagingServices/469ef25e-9bdf-4d5f-8553-eb0ce8581f30",
      params={"fields": "owners,tags"},
      headers=headers
  )

  # Get by fully qualified name
  response = requests.get(
      f"{base_url}/v1/services/messagingServices/name/sample_kafka",
      headers=headers
  )

  # Get by name with fields
  response = requests.get(
      f"{base_url}/v1/services/messagingServices/name/sample_kafka",
      params={"fields": "owners,tags,domains"},
      headers=headers
  )
  ```

  ```java GET /v1/services/messagingServices/{id} theme={null}
  import static org.openmetadata.sdk.fluent.MessagingServices.*;

  // Get by ID
  MessagingService service = MessagingServices.retrieve("469ef25e-9bdf-4d5f-8553-eb0ce8581f30");

  // Get by fully qualified name
  MessagingService service = MessagingServices.retrieveByName("sample_kafka");
  ```

  ```bash GET /v1/services/messagingServices/{id} theme={null}
  # Get by ID
  curl "{base_url}/api/v1/services/messagingServices/469ef25e-9bdf-4d5f-8553-eb0ce8581f30" \
    -H "Authorization: Bearer {access_token}"

  # Get by ID with fields
  curl "{base_url}/api/v1/services/messagingServices/469ef25e-9bdf-4d5f-8553-eb0ce8581f30?fields=owners,tags" \
    -H "Authorization: Bearer {access_token}"

  # Get by fully qualified name
  curl "{base_url}/api/v1/services/messagingServices/name/sample_kafka" \
    -H "Authorization: Bearer {access_token}"

  # Get by name with fields
  curl "{base_url}/api/v1/services/messagingServices/name/sample_kafka?fields=owners,tags,domains" \
    -H "Authorization: Bearer {access_token}"
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "id": "469ef25e-9bdf-4d5f-8553-eb0ce8581f30",
    "name": "sample_kafka",
    "fullyQualifiedName": "sample_kafka",
    "serviceType": "Kafka",
    "connection": {
      "config": {
        "type": "Kafka",
        "bootstrapServers": "localhost:9092",
        "securityProtocol": "PLAINTEXT",
        "saslMechanism": "PLAIN",
        "schemaRegistryTopicSuffixName": "-value",
        "supportsMetadataExtraction": true
      }
    },
    "tags": [],
    "version": 0.1,
    "updatedAt": 1769982621031,
    "updatedBy": "admin",
    "href": "http://localhost:8585/api/v1/services/messagingServices/469ef25e-9bdf-4d5f-8553-eb0ce8581f30",
    "deleted": false,
    "owners": [],
    "domains": []
  }
  ```
</ResponseExample>

***

## Returns

Returns a messaging service object with all requested fields populated.

## Response

<ResponseField name="id" type="string">
  Unique identifier for the messaging service (UUID format).
</ResponseField>

<ResponseField name="name" type="string">
  Messaging service name.
</ResponseField>

<ResponseField name="fullyQualifiedName" type="string">
  Fully qualified name of the service.
</ResponseField>

<ResponseField name="displayName" type="string">
  Human-readable display name.
</ResponseField>

<ResponseField name="description" type="string">
  Description of the messaging service in Markdown format.
</ResponseField>

<ResponseField name="serviceType" type="string">
  Type of messaging service (e.g., Kafka, Redpanda, Kinesis).
</ResponseField>

<ResponseField name="connection" type="object">
  Connection configuration for the service.

  <Expandable title="properties">
    <ResponseField name="config" type="object">
      Service-specific connection configuration.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="version" type="number">
  Version number for the entity.
</ResponseField>

<ResponseField name="owners" type="array" optional>
  List of owners. Only included when `fields` contains `owners`.
</ResponseField>

<ResponseField name="tags" type="array" optional>
  Classification tags. Only included when `fields` contains `tags`.
</ResponseField>

<ResponseField name="domains" type="array" optional>
  Domain assignments. Only included when `fields` contains `domains`.
</ResponseField>

<ResponseField name="followers" type="array" optional>
  Users following this service. Only included when `fields` contains `followers`.
</ResponseField>

<ResponseField name="pipelines" type="array" optional>
  Ingestion pipelines associated with this service. Only included when `fields` contains `pipelines`.
</ResponseField>

***

## Error Handling

| Code  | Error Type     | Description                                           |
| ----- | -------------- | ----------------------------------------------------- |
| `401` | `UNAUTHORIZED` | Invalid or missing authentication token               |
| `403` | `FORBIDDEN`    | User lacks permission to view this messaging service  |
| `404` | `NOT_FOUND`    | Messaging service with given ID or FQN does not exist |
