Assign
POST
/v1/admin/principal-assignments
const url = 'https://example.com/v1/admin/principal-assignments';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"tenant_id":"default","proposal_id":"example","subject_key":"example","principal_type":"human","group_path":"example","reason_code":"manual","source":"admin","effective_from":"2026-04-15T12:00:00Z","attributes":{}}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/v1/admin/principal-assignments \ --header 'Content-Type: application/json' \ --data '{ "tenant_id": "default", "proposal_id": "example", "subject_key": "example", "principal_type": "human", "group_path": "example", "reason_code": "manual", "source": "admin", "effective_from": "2026-04-15T12:00:00Z", "attributes": {} }'Parameters
Section titled “Parameters”Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
PrincipalAssignmentIn
object
tenant_id
Tenant Id
string
proposal_id
required
Proposal Id
string
subject_key
required
Subject Key
string
principal_type
Principal Type
string
group_path
required
Group Path
string
reason_code
Reason Code
string
source
Source
string
effective_from
Effective From
string format: date-time
attributes
Attributes
object
key
additional properties
any
Responses
Section titled “Responses”Successful Response
Media typeapplication/json
PrincipalAssignmentOut
object
id
required
Id
string
tenant_id
required
Tenant Id
string
subject_key
required
Subject Key
string
principal_type
required
Principal Type
string
group_path
required
Group Path
string
reason_code
required
Reason Code
string
source
required
Source
string
effective_from
required
Effective From
string
attributes
Attributes
object
key
additional properties
any
created_by
required
Created By
string
updated_by
required
Updated By
string
created_at
required
Created At
string
updated_at
required
Updated At
string
Examplegenerated
{ "id": "example", "tenant_id": "example", "subject_key": "example", "principal_type": "example", "group_path": "example", "reason_code": "example", "source": "example", "effective_from": "example", "effective_to": "example", "attributes": {}, "created_by": "example", "updated_by": "example", "created_at": "example", "updated_at": "example"}Validation Error
Media typeapplication/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Examplegenerated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}