| @@ 491-523 (lines=33) @@ | ||
| 488 | ||
| 489 | return self._send_xml_command(cmd) |
|
| 490 | ||
| 491 | def get_tls_certificates( |
|
| 492 | self, |
|
| 493 | *, |
|
| 494 | filter: Optional[str] = None, |
|
| 495 | filter_id: Optional[str] = None, |
|
| 496 | include_certificate_data: Optional[bool] = None, |
|
| 497 | details: Optional[bool] = None |
|
| 498 | ) -> Any: |
|
| 499 | """Request a list of TLS certificates |
|
| 500 | ||
| 501 | Arguments: |
|
| 502 | filter: Filter term to use for the query |
|
| 503 | filter_id: UUID of an existing filter to use for the query |
|
| 504 | include_certificate_data: Whether to include the certificate data in |
|
| 505 | the response |
|
| 506 | ||
| 507 | Returns: |
|
| 508 | The response. See :py:meth:`send_command` for details. |
|
| 509 | """ |
|
| 510 | ||
| 511 | cmd = XmlCommand("get_tls_certificates") |
|
| 512 | ||
| 513 | _add_filter(cmd, filter, filter_id) |
|
| 514 | ||
| 515 | if details is not None: |
|
| 516 | cmd.set_attribute("details", _to_bool(details)) |
|
| 517 | ||
| 518 | if include_certificate_data is not None: |
|
| 519 | cmd.set_attribute( |
|
| 520 | "include_certificate_data", _to_bool(include_certificate_data) |
|
| 521 | ) |
|
| 522 | ||
| 523 | return self._send_xml_command(cmd) |
|
| 524 | ||
| 525 | def get_tls_certificate(self, tls_certificate_id: str) -> Any: |
|
| 526 | """Request a single TLS certificate |
|
| @@ 3961-3991 (lines=31) @@ | ||
| 3958 | cmd.set_attribute("role_id", role_id) |
|
| 3959 | return self._send_xml_command(cmd) |
|
| 3960 | ||
| 3961 | def get_scanners( |
|
| 3962 | self, |
|
| 3963 | *, |
|
| 3964 | filter: Optional[str] = None, |
|
| 3965 | filter_id: Optional[str] = None, |
|
| 3966 | trash: Optional[bool] = None, |
|
| 3967 | details: Optional[bool] = None |
|
| 3968 | ) -> Any: |
|
| 3969 | """Request a list of scanners |
|
| 3970 | ||
| 3971 | Arguments: |
|
| 3972 | filter: Filter term to use for the query |
|
| 3973 | filter_id: UUID of an existing filter to use for the query |
|
| 3974 | trash: Whether to get the trashcan scanners instead |
|
| 3975 | details: Whether to include extra details like tasks using this |
|
| 3976 | scanner |
|
| 3977 | ||
| 3978 | Returns: |
|
| 3979 | The response. See :py:meth:`send_command` for details. |
|
| 3980 | """ |
|
| 3981 | cmd = XmlCommand("get_scanners") |
|
| 3982 | ||
| 3983 | _add_filter(cmd, filter, filter_id) |
|
| 3984 | ||
| 3985 | if trash is not None: |
|
| 3986 | cmd.set_attribute("trash", _to_bool(trash)) |
|
| 3987 | ||
| 3988 | if details is not None: |
|
| 3989 | cmd.set_attribute("details", _to_bool(details)) |
|
| 3990 | ||
| 3991 | return self._send_xml_command(cmd) |
|
| 3992 | ||
| 3993 | def get_scanner(self, scanner_id: str) -> Any: |
|
| 3994 | """Request a single scanner |
|
| @@ 3467-3496 (lines=30) @@ | ||
| 3464 | ||
| 3465 | return self._send_xml_command(cmd) |
|
| 3466 | ||
| 3467 | def get_overrides( |
|
| 3468 | self, |
|
| 3469 | *, |
|
| 3470 | filter: Optional[str] = None, |
|
| 3471 | filter_id: Optional[str] = None, |
|
| 3472 | details: Optional[bool] = None, |
|
| 3473 | result: Optional[bool] = None |
|
| 3474 | ) -> Any: |
|
| 3475 | """Request a list of overrides |
|
| 3476 | ||
| 3477 | Arguments: |
|
| 3478 | filter: Filter term to use for the query |
|
| 3479 | filter_id: UUID of an existing filter to use for the query |
|
| 3480 | details: Whether to include full details |
|
| 3481 | result: Whether to include results using the override |
|
| 3482 | ||
| 3483 | Returns: |
|
| 3484 | The response. See :py:meth:`send_command` for details. |
|
| 3485 | """ |
|
| 3486 | cmd = XmlCommand("get_overrides") |
|
| 3487 | ||
| 3488 | _add_filter(cmd, filter, filter_id) |
|
| 3489 | ||
| 3490 | if details is not None: |
|
| 3491 | cmd.set_attribute("details", _to_bool(details)) |
|
| 3492 | ||
| 3493 | if result is not None: |
|
| 3494 | cmd.set_attribute("result", _to_bool(result)) |
|
| 3495 | ||
| 3496 | return self._send_xml_command(cmd) |
|
| 3497 | ||
| 3498 | def get_override(self, override_id: str) -> Any: |
|
| 3499 | """Request a single override |
|
| @@ 3316-3345 (lines=30) @@ | ||
| 3313 | ||
| 3314 | return self._send_xml_command(cmd) |
|
| 3315 | ||
| 3316 | def get_notes( |
|
| 3317 | self, |
|
| 3318 | *, |
|
| 3319 | filter: Optional[str] = None, |
|
| 3320 | filter_id: Optional[str] = None, |
|
| 3321 | details: Optional[bool] = None, |
|
| 3322 | result: Optional[bool] = None |
|
| 3323 | ) -> Any: |
|
| 3324 | """Request a list of notes |
|
| 3325 | ||
| 3326 | Arguments: |
|
| 3327 | filter: Filter term to use for the query |
|
| 3328 | filter_id: UUID of an existing filter to use for the query |
|
| 3329 | details: Add info about connected results and tasks |
|
| 3330 | result: Return the details of possible connected results. |
|
| 3331 | ||
| 3332 | Returns: |
|
| 3333 | The response. See :py:meth:`send_command` for details. |
|
| 3334 | """ |
|
| 3335 | cmd = XmlCommand("get_notes") |
|
| 3336 | ||
| 3337 | _add_filter(cmd, filter, filter_id) |
|
| 3338 | ||
| 3339 | if details is not None: |
|
| 3340 | cmd.set_attribute("details", _to_bool(details)) |
|
| 3341 | ||
| 3342 | if result is not None: |
|
| 3343 | cmd.set_attribute("result", _to_bool(result)) |
|
| 3344 | ||
| 3345 | return self._send_xml_command(cmd) |
|
| 3346 | ||
| 3347 | def get_note(self, note_id: str) -> Any: |
|
| 3348 | """Request a single note |
|