RegistrationDomainService¶
- class RegistrationDomainService[source]¶
- get_all(*, tenant_id=Nothing, domain=Nothing, page_size=25)[source]¶
List registration domain rules.
- Parameters:
- Returns:
Paginated list of registration domain rules.
- Return type:
Response[AllowRegistrationDomain | BlockRegistrationDomain]
- create(json_body)[source]¶
Create a new registration domain rule.
The request body is a tagged union discriminated on the type field:
allow: maps a domain to a tenant role (requires tenant_role_id). - block: blocks registration for a domain globally.
- Parameters:
json_body (
Union[CreateAllowRegistrationDomainData,CreateBlockRegistrationDomainData]) – The body of the request. SeeCreateRegistrationDomainDatafor information about the possible fields. You can provide this data as aCreateRegistrationDomainDataor as a dictionary.
- Returns:
The created registration domain rule.
- Return type:
- delete(*, domain_id)[source]¶
Delete a registration domain rule.
- Parameters:
domain_id (
str) – The id of the rule to delete.
- Returns:
Empty response.
- Return type:
None
- patch(json_body, *, domain_id)[source]¶
Update an existing registration domain rule.
All fields are optional — only the provided fields are updated.
- Parameters:
json_body (
Union[PatchAllowRegistrationDomainData,PatchBlockRegistrationDomainData,PatchBaseRegistrationDomainData]) – The body of the request. SeePatchRegistrationDomainDatafor information about the possible fields. You can provide this data as aPatchRegistrationDomainDataor as a dictionary.domain_id (
str) – The id of the rule to update.
- Returns:
The updated registration domain rule.
- Return type: