# Retrieve a membership

`GET https://api.cademi.com.br/api/v3/automations/diamond/{diamond_id}/memberships/{membership_id}`

Operation ID: `diamonds.memberships.get` · API v3

Retrieves a lead in the Diamond, including its current stage, confirmed progress, and pending scheduled communication.

The response includes an `ETag` representing the current revision. Send this value in the `If-Match` header when moving the membership to another stage to avoid overwriting a newer version.

Credentials scoped to specific users can only access memberships of those users.

Required permissions: `diamonds.read`.

## Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `diamond_id` | path | string | yes |  |
| `membership_id` | path | string | yes |  |

## Responses

### 200

Returns the requested membership.

Body: `data`: Membership.

Fields of Membership:

| Field | Type | Required | Description |
|---|---|---|---|
| `created_at` | string (date-time) | yes |  |
| `diamond_id` | string | yes | Public ID of the Diamond, with the dmd_ prefix. |
| `enrollment_id` | string or null | yes | Public ID of the enrollment that grants access to the Diamond's internal delivery, with the enr_ prefix. |
| `id` | string | yes | Public ID, with the mbr_ prefix. |
| `last_run` | object or null | yes |  |
| `object` | string, one of `membership` | yes |  |
| `pending` | object | yes |  |
| `progress` | object | yes |  |
| `revision` | string | yes |  |
| `stage_id` | string | yes | Current stage of the lead. |
| `stage_position` | integer | yes |  |
| `updated_at` | string (date-time) | yes |  |
| `user_id` | string | yes | Public ID of the user, with the usr_ prefix. |

### 401

The credential is missing, malformed, expired, or revoked.

Body: Error.

### 403

The current credentials do not have the permission required by this operation.

Body: Error.

### 404

The membership was not found in this Diamond or is not accessible with the current credentials.

Body: Error.

### 409

Diamond automations are not enabled for the current account.

Body: Error.

Full schema: https://cademi.dev/openapi/v3.json
