Updates header and query params based on authentication setting. :param headers: Header parameters dict to be updated. :param queries: Query parameters tuple list to be updated. :param auth_settings: Authentication setting identifiers list. :param request_auth: if se
(self, headers, queries, auth_settings,
request_auth=None)
| 545 | return content_types[0] |
| 546 | |
| 547 | def update_params_for_auth(self, headers, queries, auth_settings, |
| 548 | request_auth=None): |
| 549 | """Updates header and query params based on authentication setting. |
| 550 | |
| 551 | :param headers: Header parameters dict to be updated. |
| 552 | :param queries: Query parameters tuple list to be updated. |
| 553 | :param auth_settings: Authentication setting identifiers list. |
| 554 | :param request_auth: if set, the provided settings will |
| 555 | override the token in the configuration. |
| 556 | """ |
| 557 | if not auth_settings: |
| 558 | return |
| 559 | |
| 560 | if request_auth: |
| 561 | self._apply_auth_params(headers, queries, request_auth) |
| 562 | return |
| 563 | |
| 564 | for auth in auth_settings: |
| 565 | auth_setting = self.configuration.auth_settings().get(auth) |
| 566 | if auth_setting: |
| 567 | self._apply_auth_params(headers, queries, auth_setting) |
| 568 | |
| 569 | def _apply_auth_params(self, headers, queries, auth_setting): |
| 570 | """Updates the request parameters based on a single auth_setting |