|
5 | 5 | {% from "rest/_param.py.jinja" import endpoint_params, endpoint_raw_params, endpoint_model_params %} |
6 | 6 | {% from "rest/_response.py.jinja" import build_response_type %} |
7 | 7 | {% from "rest/_request.py.jinja" import build_request, build_request_params %} |
| 8 | +{% from "rest/_docstring.py.jinja" import build_docstring %} |
8 | 9 |
|
9 | 10 | from __future__ import annotations |
10 | 11 |
|
@@ -98,10 +99,8 @@ class {{ pascal_case(tag) }}Client: |
98 | 99 | self, |
99 | 100 | {{ endpoint_params(endpoint) | indent(8) }} |
100 | 101 | ) -> {{ build_response_type(endpoint.success_response) }}: |
101 | | - {% if endpoint.external_docs %} |
102 | | - """See also: {{ endpoint.external_docs }}""" |
| 102 | + {{ build_docstring(endpoint) | indent(8) }} |
103 | 103 |
|
104 | | - {% endif %} |
105 | 104 | {{ build_request(endpoint) | indent(8) }} |
106 | 105 | return self._github.request( |
107 | 106 | {{ build_request_params(endpoint) | indent(12) }} |
@@ -131,10 +130,8 @@ class {{ pascal_case(tag) }}Client: |
131 | 130 | self, |
132 | 131 | {{ endpoint_params(endpoint) | indent(8) }} |
133 | 132 | ) -> {{ build_response_type(endpoint.success_response) }}: |
134 | | - {% if endpoint.external_docs %} |
135 | | - """See also: {{ endpoint.external_docs }}""" |
| 133 | + {{ build_docstring(endpoint) | indent(8) }} |
136 | 134 |
|
137 | | - {% endif %} |
138 | 135 | {{ build_request(endpoint) | indent(8) }} |
139 | 136 | return await self._github.arequest( |
140 | 137 | {{ build_request_params(endpoint) | indent(12) }} |
|
0 commit comments