Memberships

Memberships represent the relationship between user and organization like members.

Find Organization By UserID

GET "https://account.ezeep.com/partner/v1/users/<user_id>/memberships/?expand=organization"

Attribute Type Parameter Required Description
user_id str path Yes User UUID
limit int query No Number of results to return per page.
offset int query No The initial index from which to return the results.
expand str query No Optional. organization returns the full organization object instead of the organization’s UUID (the default).

Example Request

curl --location 'https://account.ezeep.com/partner/v1/users/7bb660df-6ef7-4654-cd38-89583f2f5bca/memberships/?expand=organization' \
    --header 'Authorization: Bearer <access_token>'

Example Response

{
    "count": 1,
    "next": null,
    "previous": null,
    "results":
    [
        {
            "organization":
                {
                    "id": "b568feca-f8ad-11ed-be56-0242ac120002",
                    "name": "Example Organization & Co.",
                    "azure_profile": null,
                    "owner": "321c5b21-6124-450d-a233-7e5fb2e14367",
                    "roles": null
                },
            "roles":
                [
                    "admin"
                ]
        }
    ]
}

Find Membership Role

GET "https://account.ezeep.com/partner/v1/users/<user_id>/memberships/<organization_id>/?expand=organization"

Attribute Type Parameter Required Description
user_id str path Yes User UUID
organization_id str path Yes Organization UUID
expand str query No Optional. organization returns the full organization object instead of the organization’s UUID (the default).

Example Request

curl --location 'https://account.ezeep.com/partner/v1/users/7bb660df-6ef7-4654-cd38-89583f2f5bca/memberships/b568feca-f8ad-11ed-be56-0242ac120002/?expand=organization' \
    --header 'Authorization: Bearer <access_token>'

Example Response

{
    "organization":
        {
            "id": "b568feca-f8ad-11ed-be56-0242ac120002",
            "name": "Example Organization & Co.",
            "azure_profile": null,
            "owner": "321c5b21-6124-450d-a233-7e5fb2e14367",
            "roles": null
        },
    "roles":
        [
            "admin"
        ]
}