Send a request with JSON body. :param input: request body, serialized to JSON if specified :return: ``(headers: dict, JSON Response: Any)`` :raises: :class:`GithubException` for error status codes
(
self,
verb: str,
url: str,
parameters: dict[str, Any] | None = None,
headers: dict[str, str] | None = None,
input: Any | None = None,
follow_302_redirect: bool = False,
)
| 605 | return Requester(**kwargs) |
| 606 | |
| 607 | def requestJsonAndCheck( |
| 608 | self, |
| 609 | verb: str, |
| 610 | url: str, |
| 611 | parameters: dict[str, Any] | None = None, |
| 612 | headers: dict[str, str] | None = None, |
| 613 | input: Any | None = None, |
| 614 | follow_302_redirect: bool = False, |
| 615 | ) -> tuple[dict[str, Any], Any]: |
| 616 | """ |
| 617 | Send a request with JSON body. |
| 618 | |
| 619 | :param input: request body, serialized to JSON if specified |
| 620 | |
| 621 | :return: ``(headers: dict, JSON Response: Any)`` |
| 622 | :raises: :class:`GithubException` for error status codes |
| 623 | |
| 624 | """ |
| 625 | return self.__postProcess( |
| 626 | verb, |
| 627 | url, |
| 628 | *self.__check( |
| 629 | *self.requestJson( |
| 630 | verb, |
| 631 | url, |
| 632 | parameters, |
| 633 | headers, |
| 634 | input, |
| 635 | self.__customConnection(url), |
| 636 | follow_302_redirect=follow_302_redirect, |
| 637 | ) |
| 638 | ), |
| 639 | ) |
| 640 | |
| 641 | def requestMultipartAndCheck( |
| 642 | self, |
no test coverage detected