class Membership (View source)

Represents the relation of a user to an organization.

Constants

ROLE_ADMIN

ROLE_WRITE

ROLE_READ

Properties

string $userId

UUID v4 of user.

string $organizationId

UUID v4 of organization.

string $role Role.
bool $active Active.

Methods

__construct(string $userId, string $organizationId, string $role, bool $active)

Constructor.

static Membership
createFromJsonResponse(string $jsonString)

Create a user from the JSON data returned by the rokka.io API.

Details

__construct(string $userId, string $organizationId, string $role, bool $active)

Constructor.

Parameters

string $userId

User id

string $organizationId

Organization id

string $role Role
bool $active

If it is active

static Membership createFromJsonResponse(string $jsonString)

Create a user from the JSON data returned by the rokka.io API.

Parameters

string $jsonString

JSON as a string

Return Value

Membership