wxc_sdk.organizations package
Organizations A set of people in Webex. Organizations may manage other organizations or be managed themselves. This organizations resource can be accessed only by an admin.
Applications can delete an Organization only after they have been authorized by a user with the Full Administrator Role which may be a user in the customer org or a user in a managing partner organization to which the role has been granted. The authorizing admin must grant the spark-admin:organizations-write scope.
- class wxc_sdk.organizations.Organization(*, id: str, displayName: str, created: datetime, xsiActionsEndpoint: str | None = None, xsiEventsEndpoint: str | None = None, xsiEventsChannelEndpoint: str | None = None, xsiDomain: str | None = None)[source]
Bases:
ApiModel
Create a new model by parsing and validating input data from keyword arguments.
Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.
__init__ uses __pydantic_self__ instead of the more common self for the first arg to allow self as a field name.
- org_id: str
A unique identifier for the organization.
- display_name: str
Full name of the organization.
- created: datetime
The date and time the organization was created.
- xsi_actions_endpoint: str | None
The base path to xsi-actions.
- xsi_events_endpoint: str | None
The base path to xsi-events.
- xsi_events_channel_endpoint: str | None
The base path to xsi-events-channel.
- xsi_domain: str | None
api- prepended to the bcBaseDomain value for the organization.
- model_config: ClassVar[ConfigDict] = {'alias_generator': <function to_camel>, 'extra': 'forbid', 'populate_by_name': True, 'use_enum_values': True}
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- model_fields: ClassVar[dict[str, FieldInfo]] = {'created': FieldInfo(annotation=datetime, required=True, alias='created', alias_priority=1), 'display_name': FieldInfo(annotation=str, required=True, alias='displayName', alias_priority=1), 'org_id': FieldInfo(annotation=str, required=True, alias='id', alias_priority=2), 'xsi_actions_endpoint': FieldInfo(annotation=Union[str, NoneType], required=False, alias='xsiActionsEndpoint', alias_priority=1), 'xsi_domain': FieldInfo(annotation=Union[str, NoneType], required=False, alias='xsiDomain', alias_priority=1), 'xsi_events_channel_endpoint': FieldInfo(annotation=Union[str, NoneType], required=False, alias='xsiEventsChannelEndpoint', alias_priority=1), 'xsi_events_endpoint': FieldInfo(annotation=Union[str, NoneType], required=False, alias='xsiEventsEndpoint', alias_priority=1)}
Metadata about the fields defined on the model, mapping of field names to [FieldInfo][pydantic.fields.FieldInfo].
This replaces Model.__fields__ from Pydantic V1.
- class wxc_sdk.organizations.OrganizationApi(*, session: RestSession, base: str | None = None)[source]
Bases:
ApiChild
- list(calling_data: bool | None = None) list[Organization] [source]
List all organizations visible by your account. The results will not be paginated.
- Parameters:
calling_data (bool) – Include XSI endpoint values in the response (if applicable) for the organization. Default: false
- Returns:
list of Organizations
- details(org_id: str, calling_data: bool | None = None) Organization [source]
Get Organization Details
Shows details for an organization, by ID.
- Parameters:
org_id (str) – The unique identifier for the organization.
calling_data (bool) – Include XSI endpoint values in the response (if applicable) for the organization. Default: false
- Returns:
org details
- Return type:
- delete(org_id: str)[source]
Delete Organization
Deletes an organization, by ID. It may take up to 10 minutes for the organization to be deleted after the response is returned.
- Parameters:
org_id (str) – The unique identifier for the organization.
- base = 'organizations'
- session: RestSession
REST session