Assign Party Role
Assigns a role to a party within a specific dock, enabling the party to participate in document workflows as either a distributor or recipient.Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
orgId | string | Required | Organization ID (prefix: org_) |
partyId | string | Required | Party ID (prefix: pty_) |
Request Body
| Parameter | Type | Required | Description |
|---|---|---|---|
dockId | string | Required | Dock ID where the role is assigned |
role | string | Required | Role type: DISTRIBUTOR or RECIPIENT |
Example Request
- Assign Distributor Role
- Assign Recipient Role
Response
Response Fields
| Field | Type | Description |
|---|---|---|
id | string | DockPartyRole identifier (prefix: dpr_) |
dockId | string | Dock where role is assigned |
partyId | string | Party receiving the role |
role | string | DISTRIBUTOR or RECIPIENT |
createdAt | string | ISO 8601 timestamp |
Validation
The endpoint validates that:- The party belongs to the specified organization
- The dock belongs to the same organization
- The role combination (dockId + partyId + role) is unique
Error Handling
| Status | Condition |
|---|---|
400 | Invalid role type or missing required fields |
401 | Missing or invalid API key |
403 | Party or dock doesn’t belong to organization |
404 | Organization, party, or dock not found |
409 | Role already assigned (duplicate) |
Multi-Role Pattern
A party can have different roles in different docks:Auto-Assignment
When creating a recipient with apartyId, if the party doesn’t have the RECIPIENT role in that dock, it’s automatically assigned.
Next Steps
After assigning a role:- Party can now participate in the dock according to their role
- Create recipients linked to this party
- Create machine clients scoped to this dock
Related Concepts
- Parties — Understanding multi-role participation
- Recipients — Access grants linked to parties
- Organizations — Scope boundary