sim_location_groups¶
The following methods allow for interaction with the ZCell SIM Location Groups API endpoints. Includes listing, retrieving, creating, updating, and deleting SIM location groups.
Methods are accessible via zcell.sim_location_groups
Copyright (c) 2023, Zscaler Inc.
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED “AS IS” AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
- class SimLocationGroupsAPI¶
Bases:
APIClient- add_location_group(id=None, query_params=None, **kwargs)¶
Creates new Sim Location Groups (bulk create).
This endpoint accepts a JSON array of group objects. The fields passed via
**kwargsdescribe a single group and are wrapped into a one-element list.- Parameters:
- Returns:
(result, Response, error)
- Return type:
The returned response supports
resp.search(<jmespath>)for client-side filtering/projection of the current page.Examples
>>> results, response, error = client.zcell.sim_location_groups.add_location_group( ... id='...', ... name='NewLocationGroup', ... geo_fence_details={'lat': '37.3382082', 'lng': '-121.8863286', 'radius': '1'}, ... ) >>> if error: ... print(f"Error: {error}") ... return >>> for item in results: ... print(item.as_dict())
- delete_sim_location_group(id=None, group_id=None)¶
Deletes an existing Sim Location Group.
- Parameters:
- Returns:
(None, Response, error)
- Return type:
Examples
>>> _, response, error = client.zcell.sim_location_groups.delete_sim_location_groups( ... id='...', ... group_id='...', ... ) >>> if error: ... print(f"Error: {error}")
- get_sim_location_group(id=None, group_id=None)¶
Get a Sim Location Group by ID.
- Parameters:
- Returns:
(result, Response, error)
- Return type:
Examples
>>> result, response, error = client.zcell.sim_location_groups.get_sim_location_groups( ... id='...', ... group_id='...', ... ) >>> if error: ... print(f"Error: {error}") ... return >>> print(result.as_dict())
- list_sim_location_groups(id=None, query_params=None)¶
Get all Sim Location Groups for a customer.
- Parameters:
id (str) – Optional. The ZCell customer ID. Defaults to the
zcellCustomerIdconfig value or theZCELL_CUSTOMER_IDenvironment variable when omitted.query_params (dict) – Map of query parameters for the request.
[query_params.name]{str}[query_params.page]{int}: Page number (0-based)[query_params.size]{int}: Page size (1-100)[query_params.sort_by]{str}: Field to sort by. Default: name. Sortable fields: id, name[query_params.sort_dir]{str}: ASC or DESC. Default: ASC
- Returns:
(result, Response, error)
- Return type:
The returned response supports
resp.search(<jmespath>)for client-side filtering/projection of the current page.Examples
>>> results, response, error = client.zcell.sim_location_groups.list_sim_location_groups(id='...') >>> if error: ... print(f"Error: {error}") ... return >>> for item in results: ... print(item.as_dict())
- update_sim_location_group(id=None, group_id=None, **kwargs)¶
Updates an existing Sim Location Group.
- Parameters:
- Returns:
(result, Response, error)
- Return type:
Examples
>>> result, response, error = client.zcell.sim_location_groups.update_sim_location_groups( ... id='...', ... group_id='...', ... name='example', ... ) >>> if error: ... print(f"Error: {error}") ... return >>> print(result.as_dict())